CodeIgniter Forums
Modular Extensions - HMVC version 5.3 - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20)
+--- Forum: Archived Libraries & Helpers (https://forum.codeigniter.com/forumdisplay.php?fid=22)
+--- Thread: Modular Extensions - HMVC version 5.3 (/showthread.php?tid=33523)

Pages: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39


Modular Extensions - HMVC version 5.3 - El Forum - 11-21-2010

[eluser]quasiperfect[/eluser]
hi

if i use Modular Extensions can i still use a global controller ?
i see that my_controller is empty can i add stuff to it and it will work or ?


Modular Extensions - HMVC version 5.3 - El Forum - 11-21-2010

[eluser]wiredesignz[/eluser]
@quasiperfect, Yes you can use a base controller. You do not need to use MY_Controller because Modular Extensions uses spl_autoload to locate base classes for you.


Modular Extensions - HMVC version 5.3 - El Forum - 11-21-2010

[eluser]InsiteFX[/eluser]
Yes! You can add your own code to it.

CI 2.0 Now uses CI_Controller not Controller.

InsiteFX


Modular Extensions - HMVC version 5.3 - El Forum - 11-25-2010

[eluser]Timothy_[/eluser]
Hello,

In post 62 it was said that:

Quote:Sub-modules are not supported.
Module controllers in sub-directories is supported.

I am not sure if I correctly understand this but I am trying to replicate my existing controller layout

Code:
application/controllers/subfolder/CONTROLLER

When I try and call a controller like this with HMVC I get a codeigniter 404 page not found.

Is there anyway around this?

Thanks,

Tim


Modular Extensions - HMVC version 5.3 - El Forum - 11-25-2010

[eluser]cryogenix[/eluser]
Hi there. First of all, I don't know where to post this question since I am not sure if it's MX's problem or the other library involved (RDM) or myself.

I would just like to ask how I could load a MY_Loader from the other library. I do believe (being the CI noob that I am) that MX's Loader has something to do with interfering with MY_Loader.

I am using CI2 + MX 5.3.5 and did pretty well setting them up quite nicely. Until I came at a loss trying to add RDM orm into the mix.


Modular Extensions - HMVC version 5.3 - El Forum - 11-25-2010

[eluser]wiredesignz[/eluser]
@Timothy_, controllers in an application/controllers/sub-directory works as it should. The URL should look something like:
Code:
http://domain.tld/index.php/sub-directory/controller



Modular Extensions - HMVC version 5.3 - El Forum - 11-25-2010

[eluser]wiredesignz[/eluser]
@cryogenix, Make sure that MY_Loader.php and the other files are located in the CI 2.0 application/core directory and make sure that the MY_Loader class extends MX_Loader.

If all else fails send Martin (the RDM author) an email.


Modular Extensions - HMVC version 5.3 - El Forum - 11-25-2010

[eluser]cryogenix[/eluser]
worked like a charm! thanks a bunch! Happy Thanksgiving (if applicable)


Modular Extensions - HMVC version 5.3 - El Forum - 11-25-2010

[eluser]Timothy_[/eluser]
[quote author="wiredesignz" date="1290701223"]@Timothy_, controllers in an application/controllers/sub-directory works as it should. The URL should look something like:
Code:
http://domain.tld/index.php/sub-directory/controller
[/quote]

Hmmm, I thought it should.

So let me confirm the directory structure from the CI root

Quote:/system/application/modules/invoices/controllers/staff/invoices

can be called from

Quote:http://domain.com/staff/invoices

This is currently resulting in a 404 for me.

However, if I cut out the STAFF subdirectory:

Quote:/system/application/modules/invoices/controllers/invoices

I can reach invoices from

Quote:http://domain.com/invoices

Any ideas on how I can troubleshoot this?

Thanks,

Tim


Modular Extensions - HMVC version 5.3 - El Forum - 11-25-2010

[eluser]WanWizard[/eluser]
@wiredesignz,

Is it possible that Modular Extensions get's support for CI's loader variable $CI->load->_ci_model_paths, so that the path to a module's models is added when you load the module?
This would allow Datamapper's model autoload method to work for MX models as well...