gpt4 book ai didi

.htaccess - .htaccess在XAMPP的localhost上不起作用

转载 作者:行者123 更新时间:2023-12-03 13:38:33 27 4
gpt4 key购买 nike

我正在使用XAMPP,但无法在本地主机上使用.htaccess文件。我尝试了很多次。。在线工作很好。但是本地主机显示 [在此服务器上找不到请求的URL]

我的根文件夹是真实的

localhost/acre/real/property_available.php
localhost/acre/real/properties


<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /acre/real/
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^properties$ /property_available.php/$1 [NC,QSA]
</IfModule>

最佳答案

刚遇到类似的问题

通过 checkin httpd.conf解决了它

     # AllowOverride controls what directives may be placed in .htaccess files.
# It can be "All", "None", or any combination of the keywords:
# Options FileInfo AuthConfig Limit
#
AllowOverride All <--- make sure this is not set to "None"

值得牢记的是,我尝试(根据Mark的回答)“。htaccess中的放置垃圾”确实给出了服务器错误-但是即使正在读取它,由于没有允许的覆盖,它也没有被执行。

关于.htaccess - .htaccess在XAMPP的localhost上不起作用,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/17162214/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com