[PHP] Re: parse URL good syntaxe please

2002-08-13 Thread lallous

you can use isset()

better grab a PHP starter document or tutorial.

Elias

Christian Ista [EMAIL PROTECTED] wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
 Hello,

 Could you tell me why on PHP 4.2.2 this code work

 ?php
   switch ($_GET['fuseaction'])
  {
 case 0:
 print i equals 0;
 break;
 default:
 print i is not equal to 0, 1 or 2;
  }
 ?

 and this one not :

 ?php
   switch ($fuseaction)
  {
 case 0:
 print i equals 0;
 break;
 default:
 print i is not equal to 0, 1 or 2;
  }
 ?

 In both cases when fuseaction is not defined, I receive an error. Could
you
 tell me how to know if the variable is defined in the URL. In coldfusion
you
 can do cfif isDefined(URL.fuseaction)

 but in php ?

 Bye





-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




[PHP] Re: parse URL good syntaxe please

2002-08-13 Thread Christian Ista


 Could you tell me why on PHP 4.2.2 this code work

My previous mail it was for my development machine, IIS, windows 2000 and
PHP4.2.2.

My host use PHP4.2.2 on linux and that's work.

Could you tell me why this difference ?

Bye



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php