-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1
Rob Church wrote:
On 20/04/07, Michael Daly wrote:
Since it's not a class, I don't use $wgAutoloadClasses. I'm avoiding making the functions part of an otherwise empty class, since I don't want to use the class::function() syntax. I could put them in a class file that contains an empty class and instantiate it just to load the file, but I was wondering if there is another, commonly accepted way to avoid this problem?
The classic approach to headers and includes, perhaps?
if( !defined( 'MYINCLUDE' ) ) { // all the include code define( 'MYINCLUDE', true ); }
You may also consider using function_exists() etc.
- -- brion vibber (brion @ wikimedia.org)