How To Change Character Encoding?
if (!$downloading && !$rssfeed) header("Content-type: text/html");
if (!$downloading && !$rssfeed){ if ($language->charset != '') header("Content-type: text/html; charset=". $language->charset); else header("Content-type: text/html");}
This thread is closed, so you cannot post a reply.
Comments on How To Change Character Encoding?
Forum Regular
Usergroup: Customer
Joined: Aug 14, 2005
Total Topics: 33
Total Comments: 107
Whenever we import javascript or anything else into our documents we find characters like ' turn into ?
After investigation we found that the site is set to Unicode(UTF-8) for the character encoding even though the actual page source says :-
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
My question is where would this problem be stemming from? We really need the site to have the correct character encoding, does anyone know where we would be able to make a change that would sort this out?
Thanks
Jon
Forum Regular
Usergroup: Customer
Joined: Aug 14, 2005
Total Topics: 33
Total Comments: 107
Hi,
Forgot to add correct encoding should be :-
Western (ISO-8859-1)
Thanks
Jon
developer
Usergroup: Administrator
Joined: Dec 20, 2001
Location: Diamond Springs, California
Total Topics: 61
Total Comments: 7868
Admin panel -> language -> find the item named charset.
If that isn't working, perhaps in end.php replace with
Forum Regular
Usergroup: Customer
Joined: Aug 14, 2005
Total Topics: 33
Total Comments: 107
Thanks Paul, cannot find anything called charset under language, is that the exact name?
Thanks
Jon
developer
Usergroup: Administrator
Joined: Dec 20, 2001
Location: Diamond Springs, California
Total Topics: 61
Total Comments: 7868
It is named charset if you're running a multilingual install. Edit for correction: actually in english-only installs too it's there.
Also see my edit above.
Forum Regular
Usergroup: Customer
Joined: Aug 14, 2005
Total Topics: 33
Total Comments: 107
Hi Paul,
May need to try the edit as I cannot see charset under language included a screenshot, that is the right section?
http://imageheap.com/main/pic.php?u=223ZShsK&i=2914
Thanks
Jon
Forum Regular
Usergroup: Customer
Joined: Aug 14, 2005
Total Topics: 33
Total Comments: 107
On the bit in the code where it says header("Content-type: text/html; charset="
Do I need to put anything in after the = sign?
Thanks
Jon
PS : Sorry no nothing about programming.
Forum Regular
Usergroup: Customer
Joined: Aug 14, 2005
Total Topics: 33
Total Comments: 107
Hi Paul,
Ok, got all that sorted and works fine now
Thank you very much
Jon
developer
Usergroup: Administrator
Joined: Dec 20, 2001
Location: Diamond Springs, California
Total Topics: 61
Total Comments: 7868
If you can't find charset I'd guess you were searching for it as content rather than name.