我正在玩我的htaccess文件,现在每次我访问我网站的根目录时都添加:/home/websitename/public_html/index.html
这非常烦人,因为我没有任何规则说它应该这样做,index.html甚至不存在于我的主机上。我该怎么办呢?
我的htaccess文件:
DirectoryIndex
RewriteEngine on
#Indexes uitzetten
Options -Indexes
#Cross site access toestaan
Header set Access-Control-Allow-Origin "*"
Header add Access-Control-Allow-Headers "origin, x-requested-with, content-type"
#Websitename
DirectoryIndex index.php
RewriteRule ^info/(.*).html catlisting.php?alias=$1 [L]
#SUBCAT
RewriteRule ^catalogus/(.*)/(.*).html cataloguslisting.php?alias_hoofd=$1&alias_sub=$2 [L]
#HOOFDCAT
RewriteRule ^catalogus/(.*).html cataloguslisting.php?alias=$1 [L]
RewriteRule ^offerte.html/(.*)/ /offerte.php?items=$1 [L]
RewriteRule ^nieuws/(.*).html nieuws.php?alias=$1 [L]
RewriteRule ^producten/(.*).html product2.php?alias=$1 [L]
RewriteRule ^lp/(.*).html lp.php?alias=$1 [L]
RewriteRule ^(.*).html content.php?alias=$1 [L]
由于我遇到了一个问题,我在this answer(第二个)玩了一下。我将[R = 301,L]添加到规则中,现在我无法将其恢复原状。