Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much
 
PerlMonks  

Re: Writing UTF8 Filename

by Juerd (Abbot)
on Nov 16, 2007 at 22:44 UTC ( #651335=note: print w/ replies, xml ) Need Help??


in reply to Writing UTF8 Filename

Have you properly encoded $stitle, $musicdir, and $title?

Juerd # { site => 'juerd.nl', do_not_use => 'spamtrap', perl6_server => 'feather' }


Comment on Re: Writing UTF8 Filename
Re^2: Writing UTF8 Filename
by amiribarksdale (Acolyte) on Nov 16, 2007 at 22:54 UTC
    Well, I am unsure about what you mean by properly encoding them. The variables write fine into MySQL and into the web pages I am producing. Just not to the actual file. For instance, further above in the subroutine, I utf_escape($title), because I do some processing on the file before I save it, and the program I use doesn't like funny names. But I figured there should be no problem writing the filename, because my filesystem can certainly handle utf8. But perl/mv seem not to be able to write it directly. Amiri

      Well, I am unsure about what you mean by properly encoding them.

      Then you very probably haven't. Please read the Perl Unicode Tutorial at http://tnx.nl/perlunitut and update your program. Perl's unicode support goes much deeper than just allowing byte strings, and typically means you have to change your input and output routines.

      Juerd # { site => 'juerd.nl', do_not_use => 'spamtrap', perl6_server => 'feather' }

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://651335]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others meditating upon the Monastery: (5)
As of 2014-08-29 04:07 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The best computer themed movie is:











    Results (275 votes), past polls