idna.module: Internationalized Domain Names conversion API

We encourage users to post events happening in the community to the community events group on https://www.drupal.org.
Konstantin Komelin's picture

Hi,

There is a good class of Matthias Sommerfeld under LGPL (called idna_convert)
http://www.phpclasses.org/package/1509-PHP-Convert-from-and-to-IDNA-Puny...

I would like to create a simple wrapper for two main methods, such as decode and encode.

Because as I know there is no another project on Drupal.org that allow to convert Punycode to UTF-8 and v.v.

In addition I want to include Matthias's class in the module folder and commit it together with module
instead of put it in sites/all/libraries folder.
Advantage of this approach is user don't have to download any files from another place except Drupal.org.

There are some related questions:
1) What do you think about the module currency? Do you know any duplicates?
2) Can I commit LGPL library to Drupal.org repo?

Comments

2) Can I commit LGPL library

Garrett Albright's picture

2) Can I commit LGPL library to Drupal.org repo?

The Legal group can help you with that. But generally, the answer to "Can I include X external code in my module" is "no" - instead, have instructions in your module's docs telling folks how they can download the library themselves, and have a hook_requirements() implementation which checks to see if the code is where it should be. Kind of a PITA, but not that hard to implement.

Thanks Garrett for good

Konstantin Komelin's picture

Thanks Garrett for good advice!

I found 3rd party libraries policy and it said the same. I cannot upload third-party code to Drupal.org repos.
http://drupal.org/node/422996

Contributed Module Ideas

Group organizers

Group notifications

This group offers an RSS feed. Or subscribe to these personalized, sitewide feeds: