ID:               50106
 Updated by:       [email protected]
 Reported By:      bugzilla33 at gmail dot com
-Status:           Open
+Status:           Bogus
-Bug Type:         Unknown/Other Function
+Bug Type:         Strings related
 Operating System: All
 PHP Version:      5.3.1RC3
 New Comment:

Thank you for taking the time to write to us, but this is not
a bug. Please double-check the documentation available at
http://www.php.net/manual/ and the instructions on how to report
a bug at http://bugs.php.net/how-to-report.php




Previous Comments:
------------------------------------------------------------------------

[2009-11-06 21:37:42] bugzilla33 at gmail dot com

Description:
------------
When use HTML 5 widt <!DOCTYPE html>
we must encode only widt &#xx;
It is not supported entity like: &amp;&quot; etc

When mime type is application/xhtml+xml and <!DOCTYPE html>
browser halt xml parsing on &amp;&quot; etc

http://pl.php.net/manual/en/function.htmlspecialchars.php
http://pl.php.net/manual/en/function.htmlentities.php

Reproduce code:
---------------
<?=htmlspecialchars('&')?>

Expected result:
----------------
'&' (ampersand) becomes '&#38;' 
'"' (double quote) becomes '&#34;'
''' (single quote) becomes '&#39;' 
'<' (less than) becomes '&#60;' 
'>' (greater than) becomes '&#62;'

Actual result:
--------------
'&' (ampersand) becomes '&amp;' 
'"' (double quote) becomes '&quot;' 
''' (single quote) becomes '&#039;' 
'<' (less than) becomes '&lt;' 
'>' (greater than) becomes '&gt;'


------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=50106&edit=1

Reply via email to