note 113658 added to mysqli.real-escape-string

From: Date: Mon, 11 Nov 2013 20:27:35 +0000
Subject: note 113658 added to mysqli.real-escape-string
Groups: php.notes 
Request: Send a blank email to php-notes+get-197492@lists.php.net to get a copy of this message
When I submit data through Ajax I use a little function to reconvert the encoded chars to their original value. After that I do the escaping. Here the function: function my_htmlentities($input){ $string = htmlentities($input,ENT_NOQUOTES,'UTF-8'); $string = str_replace('€',chr(128),$string); $string = html_entity_decode($string,ENT_NOQUOTES,'ISO-8859-15'); return $string; } G.Zanferrari ---- Server IP: 72.52.91.14 Probable Submitter: 72.52.91.14 ---- Manual Page -- http://php.net/manual/en/mysqli.real-escape-string.php Edit -- https://master.php.net/note/edit/113658 Del: integrated -- https://master.php.net/note/delete/113658/integrated Del: useless -- https://master.php.net/note/delete/113658/useless Del: bad code -- https://master.php.net/note/delete/113658/bad+code Del: spam -- https://master.php.net/note/delete/113658/spam Del: non-english -- https://master.php.net/note/delete/113658/non-english Del: in docs -- https://master.php.net/note/delete/113658/in+docs Del: other reasons-- https://master.php.net/note/delete/113658 Reject -- https://master.php.net/note/reject/113658 Search -- https://master.php.net/manage/user-notes.php

« previous php.notes (#197492) next »