View Full Version : French Strings import
Abaslith
22-02-2010, 14:39
Hi,
I've downloaded the sql dump file from the website, but, when I import them into a database, I've got some probl
Is your database using UTF8 or ISO 8856-1 (latin 1 if I wrote well the numbers)
try to change the charset that is used if you can do it, else you can try to replace all accents with html code ^^'
Abaslith
25-02-2010, 14:00
I've already tried to change the charset without success ^^ and I hope I wouldn't have to use html/php to replace every accent, because in the sql file, accent are correctly written :s
Well,
forget what you see with phpmyadmin and make your HTML page as an UTF-8 page .
ie add this in your header part of your html file:
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>Himred
Abaslith
25-02-2010, 23:05
Thank you Himred, so using an UTF8 database I'll be able to see the accent. Do you know if it's the same if I use a java program to read and display the database ?
A little java which will connect to the db, execute some simple query and then display them ?
Thanks anyway for your help :)
Well, Yes
Let's make it clear, if the string in database is for example : AB
If your program display that string in ASCII it should display : "AB"
but if you decide that your program display it in hexa, it should display : "0x41 0x42"
Again, if you decide that the program display it in binary that will give : 101001 101010
Finnaly, the data never changed in the database, in my examples you changed the interpretation of the display done by the program.
This what the html charset says to the browser which is a program ;)
Proof here: www.aionwh.com/utf8.html and www.aionwh.com/ascii.html
This is the same page, displaying the same french word from the database, the only difference is the charset defined in the head section of the html page, which explain to the browser how to interpret and display the strings.
In your case, you have to find a way in java to correctly display the string, ie say to your program that the charset to use is not ASCII but UTF-8.
I advice you to read this:
http://java.sun.com/j2se/1.4.2/docs/api/java/nio/charset/Charset.html
Regards,
Himred
Abaslith
26-02-2010, 09:14
well, Thank you very much himred, I'll try this
If there is a way to recover his files that would be fine too, thanks!
______________________________________________
macgyver seasons 1-7 dvd (http://www.dvdcollectionsale.com/MacGyver-Seasons-1-7-DVD-Boxset-DVD-1882.html)
vBulletin® v3.6.7, Copyright ©2000-2010, Jelsoft Enterprises Ltd.