Options +FollowSymLinks
IndexIgnore */*
#禁止访问目录
Options -Indexes
#404错误页面
ErrorDocument 404 /404.html
RewriteEngine on
#301带www跳转
#RewriteCond %{HTTP_HOST} !^jianzhan.love$ [NC]
#RewriteRule ^(.*)$ http://jianzhan.love/$1 [L,R=301]
#301不带www跳转
RewriteCond %{HTTP_HOST} ^jianzhan.love [NC]
RewriteRule ^(.*)$ http://www.jianzhan.love/$1 [L,R=301]
#if a directory or a file exists, use it directly
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
#otherwise forward it to index.php
RewriteRule . index.php