Modular Extensions - HMVC version 5.2 |
[eluser]Sam Dark[/eluser]
To enable profiler in CI 1.7 you need to add router binding to Controller.php. Haven't checked with CI 1.6.3: Code: /* the CI core classes */
[eluser]wiredesignz[/eluser]
@Sam, ME uses config sections by default, it always has. (allows the entire config section to be returned in one call) There is no $CI->router object in CI 1.7, what you see is a bug in the profiler class. Here's the fix I applied to Profiler.php Code: //profiler.php line 290
[eluser]wiredesignz[/eluser]
Well if the problem still exists when CI 1.7 is released I will.
[eluser]Gnative[/eluser]
Anyone interested in working on a ME5 hooks system.. ? I was looking at this http://code.google.com/p/codeigniter-extrahooks/ and thought this would be great if we have a built in system for hooks in ME, registering and running modular based hooks. Just thought i'd put it out there and see the responses.
[eluser]tdktank59[/eluser]
Just upgraded to the last release you sent out Code: A PHP Error was encountered I get that error message... Not sure if its just ME or if its everything together... Ill be looking at the problem when I get off work... However Im guessing it was my fault and i updated something wrong...
[eluser]Gnative[/eluser]
O.K this is what i got with a little play this arvo for an idea for module hooks. This will help in the separation / encapsulation of modules.. attached Module_Hooks.php (application library) in Controller.php add at line 5 Code: require_once 'Module_Hooks.php'; create hook.php files in the modules you wish to listen for a specific hook in a hooks directory. -- Module -- config -- controllers -- hooks -- hooks.php -- library -- models -- views hook.php files should have the structure Code: <?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); Module hooks will autoload hook.php files found in your modules' base in the hooks directory. It does not need the module to be initiated. to call/run a hook .. say the hook_event described above, use: Code: $output = module_hook::call('hook_event', $arg_1, $arg_2, ...); Module_Hooks will cater for multiple functions for a set event and load / run a module that is required. The function off the hook receives as arguments [ hook_data, supplied_args ] Hope i didn't make this too confusing. - It also has the function to pass on set static params in the hooks array and also set and use a specific class file.. i haven't shown this functionality here. - I spose it would possible to add a hook and remove dynamically as well thou i just whipped this up, so haven't done this yet. Just wanted to get some feedback to see what thoughts were. I'll try and upload a small app version in the morrow S |
Welcome Guest, Not a member yet? Register Sign In |