Adam Dear wrote:
I have just started using php.  I am trying to pass a parameter from one
page to another via a url ie:
     www.mysite.com/myphp.php?param=string

I am then checking the variable in the requested program, however, it isn't
working.  I try to evaluate its value in a  if statement ie:
     if($param == "string")
     {
       do something;
     }

Hmm, there was a similar question yesterday. Obviously, you have register_globals=off in your php.ini file. You can verify it either check the file php.ini directly or by www.mysite.com/phpinfo.php. Actally setting register_globals off is good for security concern. Now you can try to get the parameter by $_GET['param'].


Best

Bao

Is there something I need to configure in php to be able to accept a
variable passed via a url?

By the way, I'm new to php, so please be specific with answers.

Thanks
Adam

Reply via email to