[eluser]mvdg27[/eluser]
Hi guys,
I've got a question about modular extension hmvc, regarding extending libraries by the 'MY'-prefix. I've been fiddling around with it for a bit, but so far I haven't achieved what I was hoping to achieve.
Ok, my idea was this:
In codeigniter you can easily extend core classes by adding the MY-prefix for a class (= if I place MY_Email in the application library folder, the Core email class get's automatically extended and is available as $email->)
Now I was hoping I could do something similar with modular extensions, but then for extending my application library classes from the modules. Consider the following structure:
Code:
/application/libraries/Test.php -> Just a normal library class in application libraries folder
/application/modules/module1/libraries/MY_Test.php -> Extended Test library
Now if I would load the Test library in module1, I would automatically get the extended class and if I would load the Test library in module2 (which doesn't contain a MY_Test.php library) I would get the normal Test-library.
First question: Is this even possible with the current code? As far as I have seen it isn't.
Second question: would this be a useful feature? Does it sound like complete non-sense?

Or maybe there are other (better) options for doing this?
Third question: I'm happy to do some work on this, but I would need some pointers on where to start with this.
Cheers, Michiel