Its just a warning. It tells you that you are using a variable which has no value. Just ignore the notice, or turn down error reporting to exclude notices.
All it means is that the variable of $test which you have included in your script HAS NO VALUE. If you were to write something lile $test = "I Have A Value Now!"; then the 'error' message would disappear. Most of the time, you DO NOT WANT to give a variable a value, such as when a user submits a form to your script. The $Variables are filled by the user, not the php script. If the user misses out a field, they would see the error message you mentioned. To turn it off... go to your php.ini Search for ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ; Error handling and logging ; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; and change the line which looks like (Make sure there is no ; at the start of the line, if there is then its the wrong line to change!) error_reporting = E_ALL to error_reporting = E_ALL & ~(E_NOTICE | E_USER_NOTICE) ; display all errors and warnings This will make php only show the errors which affect the running of your scripts, not the notices such as 'Empty Variables' Hope this helps Stephen ----- Original Message ----- From: "F.Anneveld" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Monday, November 18, 2002 3:57 PM Subject: [PHP-WIN] PHP variable > Hello, > > When I use the following code my browser comes with the following error : > -------------------------------------------------------------------- > PHP code: > > <?php > if (!$test) echo "test does not exist"; > ?> > -------------------------------------------------------------------- > Browser error: > > Notice: Undefined variable: test in d:\www\trash.php on line 3 > test does not exist > > -------------------------------------------------------------------- > But in PHP you don't have to declare a variable > or do I have to ajust some setting in the PHP.ini ???? > > > Thank you, > > Frank > > > > -- > PHP Windows Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php > > -- PHP Windows Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php