• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Modules

#1
Star 
Replace 'third_party' to 'Modules' for HMVC applications!
I suggest to load module using the following code :
Code:
$this->load->module('path_inside_modules', 'rename_if_need');

then use it as codeigniter "application" like :
Code:
// path: "/www/ci/application/modules/path_inside_modules/views/welcome.php"
   $this->rename_if_need->load->view('welcome');
   // if above is impossible!
   $rename_if_need->load->view('welcome');

Just like loading library.
Module loader might need controller loader also, to execute functions in that module controller.
Ci4/Router and any related components should support modular applications by default!
Reply

#2
By the way, i`m coming from ci3, and i don't know how ci4 is working Angel Big Grin
Just want it to organized and modular application.
Reply

#3
You really need to read up on CI4 a bit ... modules, routing, namespaces.
https://codeigniter4.github.io/userguide/

There are multiple threads about this in the CI4 featire requests subforum too.

And then there are Lonnie's blogs
http://blog.newmythmedia.com/blog/show/2...eIgniter_4
Reply

#4
Then let us move this thread for Ci3. Change `third_party` to `modules` and support it future versions Ci3.1.1x
For me, Ci3 seems better and easier, i didn't like Ci4!  Confused Sick
Reply


Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2020 MyBB Group.