Bug #17204 Updated: $_GET remain always empty, whatever can be the value of register_globals
| From: | phpuser at infomediaire dot be | Date: | Thu, 04 Jul 2002 09:58:09 +0000 |
| Subject: | Bug #17204 Updated: $_GET remain always empty, whatever can be the value of register_globals | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-13095@lists.php.net to get a copy of this message | ||
ID: 17204
Updated by: phpuser@infomediaire.be
Reported By: phpuser@infomediaire.be
-Status: Feedback
+Status: Open
Bug Type: Scripting Engine problem
Operating System: NT
PHP Version: 4.2.0
New Comment:
Thank you to all for the comments.
As far as I understand now (it was not clear to me while reading the
doc), there is no way for me to get the
full http header of the request made by the client.
Only the variables (from a filled form) are available.
In my example, the request made by the client contains no
field at all. What is the equivalent of "getallheaders" while running
PHP not as an apache module but standalone ?
Previous Comments:
------------------------------------------------------------------------
[2002-06-18 16:30:03] sniper@php.net
Please add the whole script, not just some part of it..
And $_GET will always be empty, if you don't pass any
values in the URL. e.g. access the script
http://www.example.com/myscript.php?somevar=somevalue
------------------------------------------------------------------------
[2002-06-18 05:22:17] derick@php.net
Please also provide the exact way how you did this test, as I can not
reproduce this.
Derick
------------------------------------------------------------------------
[2002-05-15 07:43:38] Leblanc@somewhere.com
what about :
echo (count($_POST)."<br>");
??
/Leblanc
------------------------------------------------------------------------
[2002-05-14 07:47:32] phpuser@infomediaire.be
I'm using PHP 4.2.0. standalone (not as an apache module) on Apache
1.3.22 on NT 4.0 with SP6 (nobody's perfect ;)).
The following script
echo (count($_ENV)."<br>");
echo (count($_SERVER)."<br>");
echo (count($GLOBALS)."<br>");
echo (count($_GET)."<br>");
echo (count($_REQUEST)."<br>");
echo (count($HTTP_GET_VARS)."<br>");
give as result
31
34
48
0
0
0
The result is the same with register_globals set to on or off.
I want to access to each byte send in the HTTP header by the browser,
even if some fields are not foreseen by RFC's.
Of course I can have a look on Globals but I'm not sure
- that each line of the HTTP request will be there
- of what $Globals originate from the server or from the client.
Does anybody have the same problem ? Is it a bug ?
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=17204&edit=1