htaccess工作但网站加载不止一次

时间:2012-03-31 02:25:49

标签: .htaccess url-rewriting

我的htaccesss文件就在上面。重写是有效的,但是mysql查询有问题。例如我的计数器,计数不止一次,有时2,3或4.计数器检查cookie,如果没有cookie,则查看+1。我还在mysql上保存搜索查询。当我看sql表时,我看到所有查询字符串都保存了两次。最后,我明白问题是htaccess。没有htaccess就没有错。

Options +FollowSymLinks -MultiViews 
RewriteEngine on
RewriteBase /
RewriteRule ^about$ index.php?go=about[L]
RewriteRule ^contact$ index.php?go=contact[L]
RewriteRule ^results-(.*)$ index.php?go=results&q=$1 [L]
RewriteRule ^page-(.*)$ index.php?page=$1 [L]
RewriteRule ^(.*)-(.*)-single\.html$ index.php?title=$1&id=$2 [L,NC]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]

任何人都可以查看这些代码吗?

0 个答案:

没有答案
相关问题