Re: Static utility class?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 13-09-04 03:25 PM, Micky Hulse wrote:
I want to have a "utility" class that contain utility methods which should
have the option of being called multiple times on a page.
This sounds simply like a library of functions that are implemented using objects.

You can use the standard "require_once" in your various PHP source files so you only deal with loading the library file in the first file in which it is needed. It would not be loaded from other files.

Instantiate your static variables in the library file. Again, so that only happens once.

--
Stephen


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php





[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux