在Web浏览器上隐藏,但在Windows资源管理器上可见的目录

huangapple go评论60阅读模式
英文:

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.

huangapple
  • 本文由 发表于 2023年2月16日 02:03:48
  • 转载请务必保留本文链接:https://go.coder-hub.com/75463796.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定