PHP 4.0 Bug #9782 Updated: Warning: Undefined variable: HTTP_POST_VARS
| From: | sniper@php.net | Date: | Fri, 16 Mar 2001 11:37:44 +0000 |
| Subject: | PHP 4.0 Bug #9782 Updated: Warning: Undefined variable: HTTP_POST_VARS | ||
| Groups: | php.dev | ||
| Request: | Send a blank email to php-dev+get-49054@lists.php.net to get a copy of this message | ||
ID: 9782
Updated by: sniper
Reported By: john@neutralize.com
Old-Status: Open
Status: Feedback
Bug Type: Strings related
Assigned To:
Comments:
It would be easier to find what is wrong with your example
if it would have been complete.
Try these in your script:
print_r($HTTP_POST_VARS);
print_r($HTTP_GET_VARS);
--Jani
Previous Comments:
---------------------------------------------------------------------------
[2001-03-16 06:32:14] john@neutralize.com
The number of inputs from my form varies so I have distinguished them using a counter that
increments for each record:
<input type="text" name=Service<?php echo $counter ?> size="10">
When requesting them from the header I loop through using another counter:
while ($counter <= $noServices) {
$serviceId = $HTTP_POST_VARS['Service$counter'];
$counter++
}
No matter how I try to build the name of the post variable I always get the following error:
Warning: Undefined variable: HTTP_POST_VARS in C:Inetpubwwwroot/php/neuquote/startquote.php on line
251
I have tried buiding the string as follows:
'Service$counter'
'Service'.$counter
"Service".$counter
$postVar = "Service".$counter // put $postVar between []
I have done this in ASP before and from what I have seen from PHP so far it is more powerful, thus
hopefully one of u guys can help by a different string build or a different approuch to creating the
inputs
Thank you for your time.
John Stoops, Neutralize (**)
---------------------------------------------------------------------------
ATTENTION! Do NOT reply to this email!
To reply, use the web interface found at http://bugs.php.net/?id=9782&edit=2