#49412 [Opn]: htmlspecialchars(): Add note that most charsets don't make any difference

From: Date: Sun, 30 Aug 2009 19:31:51 +0000
Subject: #49412 [Opn]: htmlspecialchars(): Add note that most charsets don't make any difference
References: 1  Groups: php.doc.bugs 
Request: Send a blank email to doc-bugs+get-2693@lists.php.net to get a copy of this message
ID: 49412 Updated by: jani@php.net Reported By: thomas at landauer dot at Status: Open Bug Type: Documentation problem -Operating System: All +Operating System: * PHP Version: Irrelevant New Comment: There is no such OS called "All". Previous Comments: ------------------------------------------------------------------------ [2009-08-29 22:16:20] thomas at landauer dot at Description: ------------ From the 12 charsets listed in the htmlspecialchars() documentation, the following 7 are equivalent: *) ISO-8859-1 *) ISO-8859-15 *) UTF-8 *) cp866 *) cp1251 *) cp1252 *) KOI8-R Reason: The five characters affected by htmlspecialchars() [& < > " '] are all on the same position in these charsets. So for most people, the charset parameter is totally irrelevant. My suggestion: Include a note about this fact under the charset table. ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=49412&edit=1

« previous php.doc.bugs (#2693) next »