#3792 [Opn->Bgs]: ä (e.g.) is converted to ä when you got it from hidden form field

From: Date: Mon, 30 Sep 2002 22:57:21 +0000
Subject: #3792 [Opn->Bgs]: ä (e.g.) is converted to ä when you got it from hidden form field
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-20811@lists.php.net to get a copy of this message
ID: 3792 Updated by: hholzgra@php.net Reported By: marc@links2linux.de -Status: Open +Status: Bogus Bug Type: Misbehaving function Operating System: Linux 2.2.x PHP Version: 3.0.14 New Comment: browser problem php can't even determine the field type data came from, so there is no chance that it mangles hidden fields only Previous Comments: ------------------------------------------------------------------------ [2000-03-10 09:12:11] marc@links2linux.de 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------- ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=3792&edit=1

« previous php.bugs (#20811) next »