英文:
Directory hidden on web browsers but visible on windows explorer
问题
I'm having an issue similar to this
I cloned a laravel project from Github, after setting up the project on my local server (wamp) with a hostname for it, I typed the hostname on my browser (chrome) and got "500 internal server error". I had never gotten this issue before because setting up a virtual host on wamp is easy, I do it all the time.
Then I decided to view the project root directory from my browser and noticed that all the directories and files inside it were listed except the public directory.
The public directory is visible from my editor and windows explorer but is hidden when I try to view it from my Web browser thus making it impossible for me to view/run the app
How do I make visible the public directory on my browser?
Whenever I empty the .htaccess file in that public directory, it becomes visible on the browser but when I add the default laravel content of the htaccess file it becomes hidden again.
Please what could be the cause??
I tried setting the permission of that public directory to 777 using php chmod
method but directory is still hidden from browser.
英文:
I'm having an issue similar to this
I cloned a laravel project from Github, after setting up the project on my local server (wamp) with a hostname for it, I typed the hostname on my browser (chrome) and got "500 internal server error". I had never gotten this issue before because setting up a virtual host on wamp is easy, I do it all the time.
Then I decided to view the project root directory from my browser and noticed that all the directories and files inside it were listed except the public directory.
The public directory is visible from my editor and windows explorer but is hidden when I try to view it from my Web browser thus making it impossible for me to view/run the app
How do I make visible the public directory on my browser?
Whenever I empty the .htaccess file in that public directory, it becomes visible on the browser but when I add the default laravel content of the htaccess file it becomes hidden again.
Please what could be the cause??
I tried setting the permission of that public directory to 777 using php chmod
method but directory is still hidden from browser.
答案1
得分: 0
我终于看到了罪犯。
在我的htaccess文件中看到了这一行SecFilterEngine Off
,当我注释掉它时,公共文件夹神奇地出现了。我真的不知道为什么,也许与已禁用的mod_security
有关。
英文:
I finally saw the culprit.
saw this line SecFilterEngine Off
in my htaccess file and when i commented it out, the public folder magically appeared. i really don't know why, maybe it had something to do with mod_security
which was disabled.
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论