php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Request #1478 Variables passed to script
Submitted: 1999-05-31 18:03 UTC Modified: 1999-05-31 18:08 UTC
From: Nikolai at viny dot com Assigned:
Status: Closed Package: Feature/Change Request
PHP Version: 3.0.8 OS:
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: Nikolai at viny dot com
New email:
PHP Version: OS:

 

 [1999-05-31 18:03 UTC] Nikolai at viny dot com
PHP should have some way of referencing various types of
passed variables to php script.
Example:

<? SetCookie ("variable","value1", time()+3600); ?>
<form action="submit.php?variable=value2" method="post">
<input type="text" name="variable" value="value3">
<input type="submit">
</form>
 
As you see this form creates 3 variables named variable
(Cookie,URL,Form) there could be also CGI client variable.
and when form submited to submit.php, nobody knows which one would be used as $variable

Solution:
PHP should be able to reference all of those variables
as example: $Form.variable, $URL.variable , $Cookie.variable
            $CGI.variable
and if variable used as simple $variable, php should check
all of them in specified order until finds first, and use
it's value.

I see it as must-have for sites which work with big ammount
of variables and using other script engines with PHP.
____________________________
Thank you for Your attention
And Great Product.

Nikolai.

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [1999-05-31 18:08 UTC] jim at cvs dot php dot net
This already exists using php_track_vars in the form
of the HTTP_GET_VARS, HTTP_POST_VARS, and HTTP_COOKIE_VARS
arrays.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sat Mar 02 01:01:28 2024 UTC