bl******@bellsouth.net wrote:
Hi all,
I have been working on a simple form to collect user data. The form
is written in ASP. The target action is a PHP script on a completely
different system. The problem I have been experiencing is when I use
the GET method on the ASP form, my PHP page displays the data as
collected. When I use the POST method (preferred), very same PHP
page does not display the collected information. I have searched for
anything that may give me a clue on php.net but found nothing.
Please help.
Thanks
--K
1. Good god, don't cross-post to so many groups, especially when most of
them are not carried by most servers. Anyhow, on to your question -
In ASP, you access form variables by Request.Form.("VARNAME"). In PHP, it's
a bit different.
You can use either register_globals (the old method that is very frowned
upon) which lets you just use $varname, you can use $_GET['varname'] (which
only works if it's coming via GET), $_POST['varname'] ) (like $_GET but for
POST), or $_REQUEST['varname'], which is similar to ASP in that it will
search both the POST and GET inputs (if any).
Without seeing your code, I'm guessing that the script is using
$_GET['varname']. Either change this to $_POST['varname'], or if you are not
sure if you are going to use POST or GET, change it to $_REQUEST['varname'].
// Ian