Bug #3792: ä (e.g.) is converted to ä when you got it from hidden form field

From: Date: Fri, 10 Mar 2000 14:12:11 +0000
Subject: Bug #3792: ä (e.g.) is converted to ä when you got it from hidden form field
Groups: php.dev 
Request: Send a blank email to php-dev+get-16630@lists.php.net to get a copy of this message
From: marc@links2linux.de Operating system: Linux 2.2.x PHP version: 3.0.14 PHP Bug Type: Misbehaving function Bug description: &auml; (e.g.) is converted to ä when you got it from hidden form field If the value in a HTML-form-field (input-tag; type=hidden) is an HTML-Entitie (like &quot; or &gt; etc.) these Entities are converted to their real meenings (", > etc.) automatically, when you use the variablees in a Script after sending. This should NOT be! In an input-field TYPE=TEXT it IS NOT! The metthod (GET or POST) does'nt matter. Test Script: (look at source HTML-Source) after button is clicked. ----8<-------- <form method=get action=<? echo $PHP_SELF; ?>> <input type=hidden name=test value="&auml;"> <input type=submit value=TEST> </form> <? if (isset($test)) { echo "\$test (normal HTML) : $test<br>"; str_replace("&","&amp;",$test); //convert "&" to "&amp" to display &auml; echo "\$test ( Plaintext ) : $test (should be: &amp;auml;)"; } ?> ----->8-------

« previous php.dev (#16630) next »