You are here: Re: Require variable definition « PHP Programming Language « IT news, forums, messages
Re: Require variable definition

Posted by C. on 10/01/06 13:03

Alexander Fischer wrote:
>
> sorry for the Newie question: is it possible to require variables in
> PHP to be defined by the author? I'm used to this from C, and like this
> "strict" behavior, as otherwise very easily typos in variable names can
> lead to bugs...
>
> Basically, I'm looking for the PHP equivalent of VBA's "Option
> Explicit".
>

These will show up as warnings at run time.

AFAIK there is no way of making PHP flag them up as anything else (you
could write your own error handler to do this). IIRC phplint can do
offline checking of code - try google for a URL

HTH

C.

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация