note 49370 deleted from function.define by tularis
| From: | tularis@php.net | Date: | Sun, 03 Jun 2007 09:42:03 +0000 |
| Subject: | note 49370 deleted from function.define by tularis | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-127156@lists.php.net to get a copy of this message | ||
Note Submitter: tech at litigationdataservices dot com
----
If your oft-used array is already defined, but the key value doesn't start at ['0'],
--for example if you need an array of state names conforming to GIS codes, it's far easier to
define the array in a low-level class and call it by
$classname->states[$STATEID];
than it is to try to define it as a constant or use an function to call it later from a
free-standing array. It's also useful to do it this way when all you want to do is recall a
fixed array value, but don't necessarily want to hit the database just to get it.