Restrict PHP files outside application folder in CodeIgniter?

本小妞迷上赌 提交于 2019-12-25 18:52:06

问题


How can I restrict PHP files from getting executed outside the application folder?

I am using CodeIgniter and I have heard it somewhere that this thing is possible in CodeIgniter.


回答1:


Temporary, I have added request in htacess which will surpass each request from index file and will result in not found.




回答2:


Add public folder, move index.php into it, inside index.php change application and system folder settings to ../application and ../system respectively. Point domain to public folder.



来源:https://stackoverflow.com/questions/32346155/restrict-php-files-outside-application-folder-in-codeigniter

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!