aproblem Posted September 16, 2009 Share Posted September 16, 2009 Hello. Im running my own classifieds site www.ilmoitukset.org. For some reason the special letters like äöå disappear sometimes. Any idea what could be the reason? Is it fixable problem? I dont have any experience in php. It's free script that im using. Quote Link to comment https://forums.phpfreaks.com/topic/174476-disappearing-special-letters/ Share on other sites More sharing options...
MadTechie Posted September 16, 2009 Share Posted September 16, 2009 your using ISO-8859-1 encoding, change to UTF-8 Quote Link to comment https://forums.phpfreaks.com/topic/174476-disappearing-special-letters/#findComment-919577 Share on other sites More sharing options...
aproblem Posted September 16, 2009 Author Share Posted September 16, 2009 How can this encoding change by it self? Sometimes the letters are in every page, somtimes the letters are on some pages and somtimes thay arent anywhere. And where this coding could be changed? From mysql or from script? Quote Link to comment https://forums.phpfreaks.com/topic/174476-disappearing-special-letters/#findComment-919584 Share on other sites More sharing options...
MadTechie Posted September 16, 2009 Share Posted September 16, 2009 if your text is being pull from the database then add the following two queries mysql_query("SET CHARACTER SET utf8"); mysql_query("SET NAMES 'utf8'"); now on the page you need to tell the browser you using UTF-8 so add a UTF-8 header header('Content-type: text/html; charset=utf-8'); (you could also do this via a meta tag) The encoding isn't changing, its the characters to the left or right that are affecting it, for example 你好 is 2 Chinese letters BUT is made up of 5 characters ä½ å¥½ if i removed the å i'll get 你Ž Quote Link to comment https://forums.phpfreaks.com/topic/174476-disappearing-special-letters/#findComment-919590 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.