Monday 15 July 2013

php - Why are CodeIgniter application files in the public_html folder? -


Do not all files publicly see bad things?

Of course, such things /system/application/config/database.php should not be seen publicly!

Developer of CodeIgniter, Ellislabs has established this framework for ease of use. This means that people who want to try the framework do not have to brace with any permission settings on their server.

On a production server, you are absolutely right, by putting your php files in public, the HTML folder is not a good idea.

There will be a better way to organize your folders:

  • Root
    • code_igniter
      • application_folder
        • configure
        • Moderator
        • ...
      • System_foulder
      • Public _HTML
        • CSS
        • js
        • images index.php .htaccess

    To read the other changes made here, change the line 26 of index.php:

      $ System_folder = "../../code_igniter/ System-folder ";  

No comments:

Post a Comment