CodeIgniter Forums
Building frontend + backend : best practices ? - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20)
+--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23)
+--- Thread: Building frontend + backend : best practices ? (/showthread.php?tid=12387)

Pages: 1 2


Building frontend + backend : best practices ? - El Forum - 10-17-2008

[eluser]John Fuller[/eluser]
Do whatever makes sense to you. I think running the admin and the front-end as two (or more) different applications makes total sense. You can setup symlinks to share resources. Another possibility is to setup central resources and have external applications communicate with the central application via XMLRPC or whatever you want to use. Even if you do have the duplicate libraries, setup a master and then shoot your changes through your network using Rsync. Use your tools, dude!


Building frontend + backend : best practices ? - El Forum - 10-19-2008

[eluser]Thorpe Obazee[/eluser]
This is how I do it. I create 2 application directories and 2 bootstrap files. That way, I have no interaction from either front end or back end when I am working on the other.

I create another bootstrap file by copying the index.php into admin.php in the root. then I configure the bootstrap file.


Building frontend + backend : best practices ? - El Forum - 11-24-2008

[eluser]Jose Dueñas[/eluser]
[quote author="Bramme" date="1224280989"]What I do is create a subfolder in my controller folder called "admin". You can still use .htaccess to protect it, but libraries and models are shared![/quote]

For example, if you have in your controller subfolder this: admin/general.php
How do you get access to it via url?

Regards,
Jose


Building frontend + backend : best practices ? - El Forum - 11-24-2008

[eluser]pistolPete[/eluser]
Quote:For example, if you have in your controller subfolder this: admin/general.php
How do you get access to it via url?

Have a look at the documentation:

You simply access it using: http://sample.com/admin/general

But you can only have one level of subfolders!


Building frontend + backend : best practices ? - El Forum - 11-24-2008

[eluser]Jose Dueñas[/eluser]
Thanks,
I was getting a blank page because another not-related-problem.


Building frontend + backend : best practices ? - El Forum - 11-30-2008

[eluser]al404[/eluser]
[quote author="Chamyto" date="1224426098"]This is how I do it. I create 2 application directories and 2 bootstrap files. That way, I have no interaction from either front end or back end when I am working on the other.

I create another bootstrap file by copying the index.php into admin.php in the root. then I configure the bootstrap file.[/quote]

it is what i'm doing but....

but if you sset index.php and admin.php in the root, how do you configure .htaccess to remove index.php from the url?

i create index.php in the root for the public app
and a cms/index.php for the backend app

i can redirect correctly via .htaccess for the front end but not for the backend


Building frontend + backend : best practices ? - El Forum - 11-30-2008

[eluser]Thorpe Obazee[/eluser]
Yes. That's true. I really don't need to remove the 'admin.php' from the admin since only the staff will be able to see this. I only remove the one in the front end.


Building frontend + backend : best practices ? - El Forum - 03-18-2009

[eluser]leafc[/eluser]
[quote author="Isuka" date="1224283314"]

I don't password protect the folder with .htaccess, so I wouldn't know. I guess you would put it in the application/controllers/admin folder.[/quote]


I have admin directory in controller for backend purpose. I put .htaccess for password protection but it's not working. I can access admin directory without entering login and password. :ohh:


Is this supposed to work?? or Am I missing some setting to work properly?

Did anyone do this and works fine?


Building frontend + backend : best practices ? - El Forum - 05-03-2009

[eluser]Mahmoud M. Abdel-Fattah[/eluser]
[quote author="leafc" date="1237441653"][quote author="Isuka" date="1224283314"]

I don't password protect the folder with .htaccess, so I wouldn't know. I guess you would put it in the application/controllers/admin folder.[/quote]


I have admin directory in controller for backend purpose. I put .htaccess for password protection but it's not working. I can access admin directory without entering login and password. :ohh:


Is this supposed to work?? or Am I missing some setting to work properly?

Did anyone do this and works fine?[/quote]
I've same question !!