RE: [PHP-WIN] i need help with an undefined variable

From: Date: Wed, 02 Oct 2002 11:16:20 +0000
Subject: RE: [PHP-WIN] i need help with an undefined variable
Groups: php.windows 
Request: Send a blank email to php-windows+get-16129@lists.php.net to get a copy of this message
Anyang: > it's giving me this now: > Notice: Undefined index: game in C:\Xitami\webpages\index.php on line > 5 Notice: Undefined index: game in C:\Xitami\webpages\index.php on > line 8 > > because i'm opening index.php without using ?game= > is there anything I can do to not get it to say that? it's not > reading $_GET["game"] as NULL but as undefined instead. if (!isset($_GET["game"])) { $game = "?"; //well what was an expected situation for requests without game var? } else { $game = $_GET["game"]; } then carry on with the code.

« previous php.windows (#16129) next »