Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 932435
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 15, 20262026-05-15T20:40:05+00:00 2026-05-15T20:40:05+00:00

I want to build a project using codeigniter, the project consist of 2 levels,

  • 0

I want to build a project using codeigniter, the project consist of 2 levels, USER level and ADMIN level

I’m now building the ADMIN level, is it the best practice to make all my admin functions in 1 controller? like add/modify/delete users and add/modify/delete admins etc….

or make many controllers everyone has it’s job like one for add/modify/delete users and another controller for add/modify/delete admins .. and so on?

I think the second choice is better but then I will have another problem, which is separating my user level controllers from the admin level controllers

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-15T20:40:05+00:00Added an answer on May 15, 2026 at 8:40 pm

    Personally it all comes down to preference. I prefer the method of creating an admin folder in my controllers folder so accessing my controllers for the admin area happens like so:

    http://www.exampleapp.com/admin/clients
    admin is the folder name in your controllers folder
    clients is the name of the controller within the admin folder
    

    The above URL structure has it’s advantages and disadvantages (I prefer it to keep my code clean and less cluttered).

    I tend to also make one model per table in the database. So a model called users would deal with all aspects of the users table in my database. A products model would deal with all aspects of the products database table.

    You’re still adhering to the DRY (don’t repeat yourself) method because you simply include the model files you need from within your admin controllers depending on what section of the admin you’re administering.

    For your users section you could create a folder called users within your controllers folder and use the same above mentioned method.

    Phil Sturgeon (a.k.a God of Codeigniter) summed this up in his blog post, but goes into a little more detail, give it a read: http://philsturgeon.co.uk/news/2009/07/Create-an-Admin-panel-with-CodeIgniter

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am using boost build in my project and now i want to use
I have a website project that I want to build using CruiseControl.net. On one
i want to build my android project with ndk so i created my make
I'm working on a project which I want to build up OO. Now I
I want to change the build system path for building my VC++ project in
I have a maven project that I want to build without version. Now, when
I want to build a simple project using a existing archetype. But I can't
I want to make my first release of a multi-module maven project using the
I've got a project using Maven 2 as the build tool. Now I am
I have a project that I want to build using automake. The project consists

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.