Oberon has asked for the wisdom of the Perl Monks concerning the following question:
O masters of international encoding:
Perl veteran, but Unicode n00b. Let's say I have a title in a foreign language, say: "Vals På Vinkelgränd", but I need to convert it to "ASCII": that is, I want to get "Vals Pa Vinkelgrand" out of it. What Perl module can do what I want? (Note: This will be a personal script, and it will always run on 5.14.2 or higher, so I'm not worried about Unicode bugs/weird implementations in older Perls.)
For the curious, here's the application: I have a bunch of MP3 files, and many of them have these international characters (the example title is from the Movits! album Äppelknyckarjazz). I want to script a way to turn the song titles into filenames. But, unfortunately, I'm using Dropbox, and apparently its filesystem doesn't deal with Unicode characters in filenames (or filenames that differ only by case, FTM--perhaps they have a giant DOS server farm :-/ ). So, every time I store a filename with a Unicode character in it in my Dropbox folder, it comes out all garbled on the other side. So I figured the simplest thing would be to just give up, and leave the full Unicode strings in the MP3 tags, but turn the filenames into "plain ASCII." And I'd like to script this solution.
I humbly await enlightenment.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Convert international characters to plain ASCII
by graff (Chancellor) on Apr 04, 2012 at 02:04 UTC | |
|
Re: Convert international characters to plain ASCII
by moritz (Cardinal) on Apr 04, 2012 at 04:58 UTC | |
|
Re: Convert international characters to plain ASCII
by remiah (Hermit) on Apr 04, 2012 at 02:40 UTC | |
|
Re: Convert international characters to plain ASCII
by Khen1950fx (Canon) on Apr 04, 2012 at 06:51 UTC | |
|
Re: Convert international characters to plain ASCII
by DrHyde (Prior) on Apr 04, 2012 at 10:50 UTC | |
|
Re: Convert international characters to plain ASCII
by tobyink (Canon) on Apr 04, 2012 at 15:41 UTC | |
|
Re: Convert international characters to plain ASCII
by jeffa (Bishop) on Apr 04, 2012 at 21:24 UTC | |
|
Re: Convert international characters to plain ASCII
by Oberon (Monk) on Apr 14, 2012 at 06:11 UTC |