frankvw Posted March 9, 2007 Share Posted March 9, 2007 Quick one: I'm entering text in a form and after submission I run the form contents through htmlentities(). This used to work fine, but all of a sudden an e-acute in the form comes out as Ä© Apparently the data is garbled before it goes into htmlentities(). This occurs on different webservers with different browsers. I'm suspecting some character encoding issue, but I'm not sure where to look for a solution. Any pointers into the right direction would be greatly appreciated! // saybibi("Frank\n"); // Sign off Link to comment https://forums.phpfreaks.com/topic/41944-html-entities-garbled-before-conversion/ Share on other sites More sharing options...
Glyde Posted March 9, 2007 Share Posted March 9, 2007 It is most likely the character encoding of your page. My assumption is that you're probably using UTF-8 on your page. UTF-8 is great, and is widely supported, but if you want any special characters, you're going to have to look into the ISO series, maybe ISO-8859-1 Link to comment https://forums.phpfreaks.com/topic/41944-html-entities-garbled-before-conversion/#findComment-203487 Share on other sites More sharing options...
frankvw Posted March 9, 2007 Author Share Posted March 9, 2007 Thanks for the suggestion. However it didn't make any difference. My page header now says: <meta http-equiv="Content-Type" content="text/html charset=ISO-8859-1" /> but the problem remains. I put in an e-acute which comes out as Ä©. I'm not sure what's going on, as I've processed form output with PHP before and this never happened. <scratches head> saybibi("Frank\n"); // Sign off Link to comment https://forums.phpfreaks.com/topic/41944-html-entities-garbled-before-conversion/#findComment-203574 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.