RE: [PHP-DB] Can't do anything with variables
| From: | John W. Holmes | Date: | Mon, 07 Apr 2003 16:48:41 +0000 |
| Subject: | RE: [PHP-DB] Can't do anything with variables | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-142718@lists.php.net to get a copy of this message | ||
> > > It insists that you use:-
> > >
> > > if (isset($testvar)) { echo "hallo"; }
> >
> > Ummm, that has nothing to do with windows. It will work on any
platform,
> > but may give a WARNING depending on your error_reporting() level.
But
> </snip>
>
> I didn't say it has anything to do with windows, only that the windows
> version of PHP reports errors on this while other versions don't seem
to.
> Maybe I should have said 'prefers' rather than 'insists',though?
That's still bad wording. It has nothing to do with Windows or the
Windows version of PHP. It has to do with your error_reporting() level
(set in php.ini or via the function) on any platform.
At certain error_reporting levels, if($test) will throw a warning if
$test is not set. On other settings, you won't see the warning.
---John W. Holmes...
PHP Architect - A monthly magazine for PHP Professionals. Get your copy
today. http://www.phparch.com/