繁体   English   中英

.htacces到.htpasswd的路径,导致内部服务器错误

[英].htacces path to .htpasswd causing internal server error

因此,我尝试了几乎所有可能的路径,但是每次遇到内部服务器错误时,也许我正在忽略任何人有想法的东西?

.htacces的路径:/domains/domain.com/public_html/route/portfolio/inc

.htpasswd /domains/domain.com/public_html/route/portfolio/inc/etc的路径

htacces:

AuthUserFile /public_html/route/portfolio/inc/etc
AuthName "Please Enter Password"
AuthType Basic
Require valid-user

提前致谢 !

官方文档中

The AuthUserFile directive sets the name of a textual file containing the list of users and passwords for user authentication. File-path is the path to the user file. If it is not absolute, it is treated as relative to the ServerRoot.

在您的情况下,该路径被视为绝对路径,因为它以/开头。 您必须将其更改为/domains/domain.com/public_html/route/portfolio/inc/etc./public_html/route/portfolio/inc/etc

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM