PDA

View Full Version : data manager and encoding problem!


frippe
10-13-2011, 01:26 PM
Hi,

I´m having problem with special characters when creating new posts and threads thru the data manager.

If i am logged in as a user and create a post containing special chars the characters are saved in the database correctly but when i create the same post using the data manager it al goes wrong so basically "åäö" looks like this "öåä"

Ive been searching for a solution all day for this but nobody seeams to know how to fix it so if any of you guys know how to solve this i would appreciate it alot!

PS.
I have tried to encode the string to iso-8859-1 and utf8 but i get the same result!

Thanks in advance

kh99
10-15-2011, 12:36 PM
That character encoding stuff always confuses me, but I did some experiments and found that if I call utf8_decode on your string it seems to work. I guess maybe that means if you include special characters in a php string it's utf8 encoded, but it needs to be ISO-8559-1 when passed to the data manager (or I suppose it needs to be whatever character set you have your forum configured to use).