LinuxQuestions.org
LinuxAnswers - the LQ Linux tutorial section.
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices

Reply
 
Search this Thread
Old 12-21-2004, 05:33 AM   #1
synna
Member
 
Registered: Jan 2004
Posts: 40

Rep: Reputation: 15
How to know encoding used for filename


Hi,

For a project I need to know wich encoding (ISO-Latin1 or UTF-8...) is used for path and filename. Is this always the same ?
can I assume something ?

I use iconv to convert encoding (actually all the app is in UTF-8) and I can't use a library for this.

Thanks for your response.
 
Old 12-22-2004, 10:57 AM   #2
Mara
Moderator
 
Registered: Feb 2002
Location: Grenoble
Distribution: Debian
Posts: 9,539

Rep: Reputation: 149Reputation: 149
Well, you can check if there are UTF-8 characters in the path. And that's the only way. But... it'll fail if other encoding is used.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
change uploaded files from filename.avi to filename.avi.html like www.rapidshare.de latheesan Linux - Newbie 3 06-16-2005 05:33 AM
filename~ djc Suse/Novell 2 02-14-2005 02:52 PM
@ in filename Hamsjael Linux - Software 4 01-27-2005 02:05 PM
filename- and filename~ files? slinky2004 Linux - Newbie 5 10-17-2004 11:32 PM
\ in filename cblamer Slackware 6 12-20-2003 03:40 PM


All times are GMT -5. The time now is 10:31 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration