Modular Separation for CodeIgniter 2

Posted: 2010-03-24
Category: CodeIgniter

Sadly CodeIgniter 2.0-dev has not brought us any sort of modular/HMVC system, but luckly Modular Separation works for this new "version" with two minor tweaks.

The fix was worked out a few hours after the CodeIgniter 2.0 dev code was released but I was hoping wiredesignz would incorporate and re-post. Sadly the man has other commitments to attend to, so I have released the patched version.

I will use this fork to work on some cool new CodeIgniter 2.0 related features such as supporting Packages as well as the existing custom "module location" array.

Note: In no way is this intended as theft of wiredesignz work. He is a brilliant developer who I have a great deal of respect for, so please notice his name is still on every file with only "@modified Phil Sturgeon" added in. I have patched his work.

Update: There was some confusion in this post with my wording. CodeIgniter 2.0 is not officially released yet, I am talking about the development code. DO NOT use CodeIgniter 2.0 on any live sites just yet, I will post an update when I feel confident enough to run CodeIgniter 2.0 on my live sites.

Comments

Gravatar
Anil

2010-03-25

Hi phil,

I follow your website regularly,you do a good job keep it up. I have one question regarding codeigniter 2.0 - is it better to wait until the final version or can i start working with 2.0, i saw you are changing pyrocms to 2.0, Did you face any problems using this. We are starting a new project in our company and how hard it will be to upgrade from 1.7.2 to 2.0 in future.

Gravatar
Amit

2010-03-25

"The fix was worked out a few hours after CodeIgniter 2.0 was released"

Released? Where? CI 2.0 is still in development, hasn't made it out yet.

Gravatar
Patrick Fraley

2010-03-25

CodeIgniter 2.0 was released? Where can one find it? On CodeIgnter.com it is still 1.7.2?

Gravatar

2010-03-25

Hold your horses guys, CodeIgniter 2.0 is still in development, but the codebase has been released. I am getting my code working with it so I can play along with the development changes and bug-fixes as they come in.

Do NOT start deploying websites with CodeIgniter 2.0 just yet, there are still some major bugs to be sorted out. I have squashed a few of them and have one left that I am going to look at tonight. I'll post an upgrade guide when I believe CodeIgniter 2.0 is ready to go into use.

Btw, PyroCMS is running perfectly on CodeIgniter 2.0 :-)

Gravatar
Anil

2010-03-25

Hi Phil,
Thanks for the answer,

Every one in Codeigniter community try to develop a CMS (Which I really appreciate), but no one tries to do a basic structure or some basic modular development structure which will allow us to use it more ways than possible now. I am not sure whether you got my point or not, I mean if I want to develop a CRM I should be able to use the basic structure and develop it, If I want to develop a website I should be able to do it, If I have to do something else I should be able to do it. I know we can modify Pyro CMS to do all this stuff which i am doing now.. but I think you will know a better solution for this may be..

Gravatar
Anil

2010-03-26

Please add a search function to this website.. :) It is getting little hard to find tutorials dated back.

Cheers,
Anil

Gravatar
Emmanuel

2010-04-04

Hi Phil,

Having a slight issue applying the update. I am just testing out a fresh alpha copy of CI2.0. I have copied the patched files to the application's libraries folder, created a modules folder and a page module. Unfortunately, when I try to access the module, I get a "404 Page Not Found" error.

What could I be doing wrong?

Gravatar
Luke

2010-06-26

just to let everyone know... you need to put these in the application/core folder as of latest codeigniter 2 version... placing them in application/libraries is in older versions.

Gravatar
Matt

2010-06-28

Just tried implementing module separation 2.1 from the bitbucket repo. , and it was looking for My_config. So i stole it from pyrocms and it worked fine :)

Gravatar
Akhmad

2011-03-21

Phil, I like your job, may I get link for download "Modular Separation for CodeIgniter 2".
Thank you!

Gravatar

2011-03-21

Use Modular Extensions (HMVC) instead:

http://bitbucket.org/wiredesignz/codeigniter-modular-extensions-hmvc

Gravatar
Akhmad

2011-03-21

Thank you very much,
I'm studying pyroCms script, I like your script,
What pyroCms use like this one too?
Or different system?
Thanks...

Gravatar
Smi

2011-07-09

Can not find good examples for Modular Extensions (HMVC).
May be somebody know usefull links?

Gravatar
Lady

2011-08-30

add a search function is good advice

Posting comments after three months has been disabled.