At 12:48 PM 03/02/2001 -0700, Joe wrote:
>is there any real benefit to declaring a CONSTANT over just defining a 
>variable?

The fact they can't be overwritten makes them more appropriate for true 
constants, absolutely no way to change their values.  I frequently use them 
in include files to set widths, etc., that are brought into all the pages 
in a project.

Plus, they have global scope - great if you are in the habit of forgetting 
global declarations in functions <g>.

And my guess is their is less overhead in using them, even in an 
interpreted environment.


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to