php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #27863 $_GET var problem
Submitted: 2004-04-05 03:47 UTC Modified: 2004-04-05 05:13 UTC
Votes:2
Avg. Score:2.0 ± 1.0
Reproduced:0 of 1 (0.0%)
From: rudenko at id dot com dot ua Assigned:
Status: Closed Package: *General Issues
PHP Version: 4.3.4 OS: Fedara Core 1 (Yarrow)
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: rudenko at id dot com dot ua
New email:
PHP Version: OS:

 

 [2004-04-05 03:47 UTC] rudenko at id dot com dot ua
Description:
------------
When I unset value of array which equal to $_GET superglobal, php unsets element in $_GET superglobal, but not in this array.

Reproduce code:
---------------
<? 
echo '<pre>'; 
$x = $_GET; 
print_R($x); 
unset($x['id']); 
print_R($_GET); 
?> 

Expected result:
----------------
Array ( [test] => 123 ) 
Array ( [test] => 123 [id] => 5 )

Actual result:
--------------
Array ( [test] => 123 [id] => 5 )
Array ( [test] => 123 ) 


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2004-04-05 03:59 UTC] tony2001@php.net
I've tested it with PHP 5-CVS, 4.3-CVS, 4.3.4 & 4.3.3 and I'm not able to reproduce this behaviour.

Try to turn off Zend Optimizer, I already saw some similar complaints.
 [2004-04-05 04:15 UTC] rudenko at id dot com dot ua
At the moment I use Zend Optimizer 2.5.0

When I turn off Zend Optimizer, script work correctly
 [2004-04-05 05:13 UTC] rudenko at id dot com dot ua
Zend Optimizer bug fixed in version 2.5.1
 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Wed Mar 12 10:01:31 2025 UTC