RE: [PHP] Problems with HTML forms and PHP. Please Help !!
| From: | Martin Towell | Date: | Mon, 05 Aug 2002 01:06:34 +0000 |
| Subject: | RE: [PHP] Problems with HTML forms and PHP. Please Help !! | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-111122@lists.php.net to get a copy of this message | ||
do a phpinfo() and look at the end to see what variables are set - maybe
this will help shed some light on the problem (??)
-----Original Message-----
From: Mr. Nobody aka Rick Hays [mailto:mr.nobody@nowhereville.com]
Sent: Monday, August 05, 2002 10:42 AM
To: php-general@lists.php.net
Subject: Re: [PHP] Problems with HTML forms and PHP. Please Help !!
I have been having the same problem... I have tried several way to get to
the GET items with no success
If I do this (http://localhost/index.php?P=3&ID=413) I get nothing back..
Here are several way I have tried..
$var_http_get = 'HTTP_GET_VARS';
$local_http_get = $$var_http_get;
print $local_http_get['P'] . '*<BR>';
echo "<br><hr>";
echo "REQUEST<BR>";
foreach($_REQUEST as $Value)
{
print "REQUEST=" . $Value . "<BR>";
}
echo "<br><hr>";
$h = "_GET";
foreach($$h as $Value)
{
print $Value;
}
echo "<br><hr>";
foreach($_GET as $Value)
{
print "GET=" . $Value . "<BR>";
}
echo "<br><hr>";
foreach($_POST as $Value)
{
print "POST=" . $Value . "<BR>";
}
echo "<br><hr>";
foreach($_SERVER as $Key => $Value)
{
print "SERVER (" . $Key . ") - " . $Value . "<BR>";
}
echo "<br><hr>";
The only thing I get back is from the $_SERVER which looks like (Only posted
a few of them)
SERVER (REQUEST_METHOD) - GET
SERVER (SCRIPT_NAME) - /INDEX.PHP
SERVER (REQUEST_URI) - /INDEX.PHP?P=3&ID=413
SERVER (REQUEST_LINE) - GET /INDEX.PHP?P=3&ID=413 HTTP/1.1
SERVER (USER_AGENT) - Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1;
.NET CLR 1.0.3705)
So it appears that the data is getting to the PHP.EXE but nothing comes out,
this is GLOBAL set to ON and OFF in the PHP.INI...
"Bob Lockie" <bjlockie@lockie.ca> wrote in message
news:200208030219.g732JtdN026301@gw.lockie.ca...
Is register_globals off in your php.ini?
Try $var = $_REQUEST['var'];
>Hi! i have instaled PHP 4.2.2 in a slack 8.1 running apache 2.0.39.
>i have a proble with a very basic script (pass variables to a php
>script). Is seems not recieve variables, because print somthing like this:
>
>Your first name is .
>Your last name is .
>Your E-mail address is .
>This is what you had to say:
>
>In the server log say the variables appear don´t exist.
>Here i send this windows files (i try in XP with iis 5.1 and PJP 4.2.2
>and is the same problem) to help you to help me :)
>ah! php is working because i test the <? phpinfo(); ?> stuff and works !!!
>
>Tanks
>
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php