|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
[2006-05-18 07:01 UTC] serkan dot kibritoglu at gmail dot com
Description:
------------
Very simple logic. Here you go;
Reproduce code:
---------------
if($_GET['param']=='') $_GET['param'] = "I am changed forever.";
echo "Should print: " . $_GET['param'] . "<br>\n";
import_request_variables("g", "g_");
echo "And... !: " . $g_param . "<br>\n";
Expected result:
----------------
Should print: I am changed forever.
And... !: I am changed forever.
Actual result:
--------------
Should print: I am changed forever.
And... !:
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Tue Nov 18 06:00:01 2025 UTC |
I am sorry to re-open this bug but it is very very similar to this one. Reproduce code: --------------- foreach($_POST as $key => $value) { $_POST[$key] = trim($value); $_POST[$key] = strip_tags($value); $_POST[$key] = mysql_real_escape_string($value); } Expected result: ---------------- The code above should; trim, strip_tags and mysql_real_escape_string to the original values but it only applies the last function in foreach, which is mysql_real_escape_string. When i replace the trim() line to the end, it only trims and so on.. I think same goes for _GET and _COOKIE values as well.