Php error on isset() function?
Posted: Sat Jan 04, 2003 10:15 am
Hi @all!
I have a question! When I use the isset() function in a PHP script, for example like that:
<?
if(!isset($var)){
echo "Hello World!";
}
else{
echo "ERROR!";
}
?>
and later I look in my error.log file and have got an error:
[Sat Jan 4 16:27:03 2003] [error] PHP Notice: Undefined variable: var in /usr/home/fsascha/htdocs/script.php on line 2
I know the variable was not declared previously! Is this error normal?
Thanks for helping!
I have a question! When I use the isset() function in a PHP script, for example like that:
<?
if(!isset($var)){
echo "Hello World!";
}
else{
echo "ERROR!";
}
?>
and later I look in my error.log file and have got an error:
[Sat Jan 4 16:27:03 2003] [error] PHP Notice: Undefined variable: var in /usr/home/fsascha/htdocs/script.php on line 2
I know the variable was not declared previously! Is this error normal?
Thanks for helping!