php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #3792 ä (e.g.) is converted to ? when you got it from hidden form field
Submitted: 2000-03-10 09:12 UTC Modified: 2002-09-30 17:57 UTC
From: marc at links2linux dot de Assigned:
Status: Not a bug Package: Misbehaving function
PHP Version: 3.0.14 OS: Linux 2.2.x
Private report: No CVE-ID: None
 [2000-03-10 09:12 UTC] marc at links2linux dot de
If the value in a HTML-form-field (input-tag; type=hidden) is an
HTML-Entitie (like " or > 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-------

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2002-09-30 17:57 UTC] hholzgra@php.net
browser problem

php can't even determine the field type data came from,
so there is no chance that it mangles hidden fields only
 
PHP Copyright © 2001-2019 The PHP Group
All rights reserved.
Last updated: Tue Mar 26 18:01:26 2019 UTC