Undefined Variable errors

From: Date: Mon, 11 Nov 2002 18:10:28 +0000
Subject: Undefined Variable errors
Groups: php.general 
Request: Send a blank email to php-general+get-123883@lists.php.net to get a copy of this message
Hello, I'm migrating to PHP from ColdFusion. I've been running some sample scripts I have found in various places and all of them throw an error: Notice: Undefined variable: <varname> in c:\inetpub\wwwroot\myphpcalendar\<somefile.php> on line <someline>. In ColdFusion, I can use the <cfparam> tag to preset a variable. I've tried the following code to define the variable in PHP, but it doesn't work: if (!isset($VarName)) { $VarName = 0; } Is there a setting in php.ini or a call in the beginning of the script that I need to use? Thanks, James Johnson Owell Technologies james@owell.com

« previous php.general (#123883) next »