Welcome Guest, Not a member yet? Register   Sign In
CMS structure
#1

[eluser]eeerlend[/eluser]
If you are creating a CMS with CodeIgniter, how would you organize the folders, and WHY?

It would be interesting to hear some thougtsSmile
#2

[eluser]WanWizard[/eluser]
We didn't organize folders, the entire content tree of the site is loaded from the database, no physical folder tree on disk.

Every page in the tree is defined by a master template, which defines the page layout and the 'slots' available for page elements (widgets).
Every page element is a Modular CI controller method, also defined in the database. When a page is requested, the two are merged and the page is generated.
#3

[eluser]eeerlend[/eluser]
[quote author="WanWizard" date="1284821304"]We didn't organize folders, the entire content tree of the site is loaded from the database, no physical folder tree on disk.

Every page in the tree is defined by a master template, which defines the page layout and the 'slots' available for page elements (widgets).
Every page element is a Modular CI controller method, also defined in the database. When a page is requested, the two are merged and the page is generated.[/quote]

I also prefer to load the entrie structure from the database... But what about, lets say, "templates", "assets" or "images" that is being implemented? Do you make folders like /templates/, /images/, /cache/, etc...?

And the admin part, do you use the same collection of MVC-files, or do you make a stand-alone admin application?
#4

[eluser]InsiteFX[/eluser]
If you took the time to look at some of the Codeigniter
CMS's on the forum you find all your answers!

PyroCMS
ExiteCMS
etc.

InsiteFX
#5

[eluser]Boris Strahija[/eluser]
I'm currently working on my own CMS and the structure looks somethign like this (Krustr is the name of the CMS):

Code:
krustr
- assets
-  - cache
-  - css
-  - images
-  - js
- controllers
- ...
- system (CI sytem folder)
- third_party
themes
- _mailing
- modernist
- ...
uploads
- entries
- galleries
- ...

Works fine for me Wink
#6

[eluser]Mr. Pickle[/eluser]
I have modules (with their own controllers and models).
Each module gets a folder in the views folder.

So

views
- news
- save
- delete
- read
- pages
- save
- delete
- read
- etc ...
- save
- delete
- read

The save page manages both the create and update from the CRUD.
the read and delete pages are separate.
They all correspond with the read, save and delete functions in the controller and model.

The menu is generated in a global file checking the controller and action at that moment to give the active menu an active css style.
#7

[eluser]Phil Sturgeon[/eluser]
[quote author="Boris Strahija" date="1285001789"]I'm currently working on my own CMS and the structure looks somethign like this (Krustr is the name of the CMS):

Code:
krustr
- assets
-  - cache
-  - css
-  - images
-  - js
- controllers
- ...
- system (CI sytem folder)
- third_party
themes
- _mailing
- modernist
- ...
uploads
- entries
- galleries
- ...

Works fine for me ;)[/quote]

Yep thats pretty much how everyone is doing it Smile




Theme © iAndrew 2016 - Forum software by © MyBB