Re: ASP Option Explicit equivalent in PHP
| From: | Marco Tabini | Date: | Wed, 09 Oct 2002 22:48:18 +0000 |
| Subject: | Re: ASP Option Explicit equivalent in PHP | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-119472@lists.php.net to get a copy of this message | ||
Well, you can set error_reporting to E_ALL, which will cause PHP to
complain if you use a variable without having it initialized. There is
no exact equivalent to Option Explicit--and there still isn't any need
to declare the variables, just to initialize them before use.
Marco
On Wed, 2002-10-09 at 18:47, R. Z. wrote:
> I'm on a roll with the ASP questions these days, since I picked up the
> Chiliasp.
>
> Here's one:
>
> ASP has the function Option Explicit build in, it yells when you use
> variables without prior declaration, couldn't find anything like that in
> PHP documentation.
> Thanks in advance.
>
> R>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>