ID:               25927
 Comment by:       kees at tweakers dot net
 Reported By:      acm at tweakers dot net
 Status:           Open
 Bug Type:         Unknown/Other Function
 Operating System: Linux
 PHP Version:      4.3.3
 New Comment:

We've fixed it be commenting line 421 of ext/standard/html.c:

420-    { '\'', "'",       6,      ENT_HTML_QUOTE_SINGLE },
421:/*  { '\'', "'",        5,      ENT_HTML_QUOTE_SINGLE }, */


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

[2003-10-20 17:53:29] acm at tweakers dot net

Description:
------------
When you call get_html_translation_table, with the ENT_QUOTES
parameter, it'll return ' for '

The code for ' should, of course, be '

This was not broken in 4.3.1, so is newly introduced in either 4.3.2 or
4.3.3

One wonders how this could occur, since both
htmlspecialchars/htmlentities and html_entity_decode work correctly.

Reproduce code:
---------------
<?       
print_r(get_html_translation_table(HTML_SPECIALCHARS,ENT_QUOTES));
?>

Expected result:
----------------
Array
(
    [&] => &amp;
    ["] => &quot;
    ['] => &#039;
    [<] => &lt;
    [>] => &gt;
)


Actual result:
--------------
Array
(
    [&] => &amp;
    ["] => &quot;
    ['] => &#39;
    [<] => &lt;
    [>] => &gt;
)



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


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

Reply via email to