Re: note 14275 added to pear.standards.constants.php

From: Date: Wed, 25 Jul 2001 17:12:20 +0000
Subject: Re: note 14275 added to pear.standards.constants.php
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-15835@lists.php.net to get a copy of this message
Hey Bob, The note is appropriate for the variables section of the manual, but probably not for the PEAR constants section. This section documents the naming conventions PEAR uses - instead of the naming conventions you use. :) --zak ----- Original Message ----- From: <bobt@elmwood.com> To: <php-notes@lists.php.net> Sent: Tuesday, July 24, 2001 4:46 PM Subject: [PHP-NOTES] note 14275 added to pear.standards.constants.php > Naming conventions for variables. > > When reading code, it is important to be able to easily tell where a variable came from, and what kind of variable it is. > > To this end, I use: > $lv_ for local, throwaway variables > $sv_ for session variable > $sc_ for session constant > $fv_ for form variable > $fc_ for form constant ( provided by "hidden" tag ) > > Personally, I don't like PHP constants, because they don't require the leading $, and I don't like much of anything in all upper case. This is why I use "$sc_". It just tells me this value should never be changed. > > http://www.php.net/manual/en/pear.standards.constants.php

« previous php.notes (#15835) next »