CodeIgniter Forums
What should my folder permissions look like? - 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: What should my folder permissions look like? (/showthread.php?tid=31207)



What should my folder permissions look like? - El Forum - 06-10-2010

[eluser]kaos78414[/eluser]
The title pretty much says it all; I haven't moved my site to a server yet, (just building it locally and getting some much needed practice with codeigniter), but when I do, I was curious as to how my folder permissions should look? I'm sure some folders need stricter permissions then others, but for the ones that need to remain writable, like the cache folder, should I 777 it or...? (As you can tell I'm a bit new to folder permissions)


What should my folder permissions look like? - El Forum - 06-10-2010

[eluser]Rob Gordijn[/eluser]
in short, this is my approach:

- /system/ folder placed 1 level lower then the 'public_html' folder, specify this in the index.php
- /system/cache/ to 777
- if you create an upload dir (for images or whatever) you probely need it to 777, but remember to secure this folder with some htaccess (for example: no posting allowed)

cheers!


What should my folder permissions look like? - El Forum - 06-10-2010

[eluser]kaos78414[/eluser]
How would I specify that the system folder is one level up from public html? (I've never done anything like that before)


What should my folder permissions look like? - El Forum - 06-10-2010

[eluser]Rob Gordijn[/eluser]
in the index.php:

Code:
$system_folder = "../system";


and if you leave the /application/ folder in the /system/ folder, you're done.

cheers