Welcome Guest, Not a member yet? Register   Sign In
Separate Client Portal from main app
#5

(11-17-2015, 03:25 AM)Sentro Wrote: Hello,

I have an application running and about to create a client portal.
Database is the same. What would be the best way to separate the client's portal from the main app??

Split the controllers into folders, one for the "admins" and one for the clients ?

What would be my best option ( security based also ) ?

I've seen people splitting the session also into arrays ( admin,client ) but that would mean a lot of changes for the current
code. I guess i can always use different session variables to check for stuff??

Any help or guidance would be appreciated.

Thank you

Hi,

I think you can make two folders in controllers for backend and frontend and the same at views, and share the models. In addition to this at MY_Controller php file you can add Backend_Controller for extend all backend controllers from it and where you must to check authorization, and put all functions that you need in backend controllers. You can use MY_Controller for frontend controllers.

- core
  - MY_Controller.php
    - class MY_Controller
    - class Backend_Controller
- controllers\
  - backend\
  - frontend\
- models\
- views\
  - backend\
  - frontend\
Greetings.
Reply


Messages In This Thread
Separate Client Portal from main app - by Sentro - 11-17-2015, 03:25 AM
RE: Separate Client Portal from main app - by rtorralba - 11-17-2015, 04:46 PM



Theme © iAndrew 2016 - Forum software by © MyBB