Re: Re: class_is_loadable?

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

 



Pulni4kiya wrote:
Well reimplementing autoloading doesn't seem such a bad idea.
With the integrated autoload ...there is one very stupid way of doing what you want. Something like this (I suppose you know which class is the parent of the one that is 'missing'):
eval("class $class_name extends THE_PARENT {}");
You can put a field with the actual class name and fill it in the constructor so you would know if it's the actual class B or just A with a different name.

(What I just wrote looks very stupid... Don't laugh at me very much please. :D)

I'll think of something smarter...this is the first thing that came into my mind.

Btw why is it so important to use autoloading anyway?

Hi,

Has anybody used the PECL extension automap yet and if so, are there issues with using that to autoload or not?

Greetings,

Aschwin Wesselius

--
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