Welcome Guest, Not a member yet? Register   Sign In
CI Coding Advice : Linking Modules to Pages
#1

[eluser]opel[/eluser]
I have managed to successfull create a CMS system using the Modular Extensions Library, SimpleTemplate library and good advice from this forum.

However I have come to one problem that I'm not sure what the best way to approach it is and require some advice.

I have used the libraries above so that I can move modules around different projects, similar to DJango apps.

The final thing I want to do is link my "pages" module to each of my other modules so that a user can manage some text on each module to explain how to use it.

My initial idea was to create a table in the database that administrator can manually add in modules and methods that pages can have content added to.

However after looking at Codeigniters hooks and libraries I think there may be a better way to do this without creating anything in the database. The only person to manage the modules will be the site developer, not an administrator.

Could anyone advise on what the best way to use CI t tackle this problem ?

Thanks in advance.
#2

[eluser]TheFuzzy0ne[/eluser]
I'm sorry, but I for one don't understand what you're trying to achieve. Is there any chance you can show an example of your code that might shed some light on what you want to do?
#3

[eluser]opel[/eluser]
Sorry it is a little confusing as I haven't started written it yet.

Basically if I had a "Blog" module with an "Index" and "Article" method I am trying to allow the site administrator to be able to add in text for those pages via another module that I am calling "Pages". So on index page they could have an intro about the blog etc.

My plan to tackle this was to create a modules table to add in modules and the editable methods and simply join it to the pages modules.

However, after lookng through the CI forum and manual I am wondering if using Hooks and/or libraries may be a more efficient way to manage the above. As the site developer i.e. me is only person setting the modules creating a db table may be overkill?

I hope this is a little clearer?
#4

[eluser]TheFuzzy0ne[/eluser]
Unfortunately not, but then again, I am a little bit dim. I'm sure someone else may be able to help, however.
#5

[eluser]opel[/eluser]
I think I have a plan to use a library and a hook. If I get it working I'll paste my results




Theme © iAndrew 2016 - Forum software by © MyBB