note 107142 deleted from function.html-entity-decode by danbrown

From: Date: Tue, 10 Jan 2012 20:11:05 +0000
Subject: note 107142 deleted from function.html-entity-decode by danbrown
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-185527@lists.php.net to get a copy of this message
Note Submitter: Gundars ---- Please note that "Anonymous 02-Oct-2008 11:40" author is wrong saying "The previous post seems incorrect. Even if PHP sets the charset, it can be overridden if HTML charsets are sent via META tags beforehand." HTML may override it on display, but the ENT_QUOTES in syntax addslashes(html_entity_decode($x, ENT_QUOTES); is neccesery, when converting text before adding it to mysql_query. Without ENT_QUOTES text will read fine utf-8, except hexdec symbols. Leaving out ENT_QUOTES results in " ' " being inserted as '

« previous php.notes (#185527) next »