> Could someone please tell me why i get the following Notice Message
> Notice: Undefined variable: PHP_SELF in
> g:\apache_web\intern\looney\index.php on line 101
> Code affected:
> function WriteNewArticle()
> Line 100: $smarty = new Smarty;
> Line 101: $smarty->assign("PHPSELF", $PHP_SELF);
> // etc.....
Why? Because $PHP_SELF is an undefined variable. There is nothing
assigned to it and you're trying to use it in a function.
But, you say, $PHP_SELF is supposed to be the current page. Yes,
normally it would with register_globals ON, but you are inside of a
function, so it is a whole new variable now.
So, like someone else suggested, make it global inside your function
Or, if you're on a new version, just use $_SERVER['PHP_SELF'] and you
don’t have to worry about global.
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php