[ISAPI_Rewrite] # 3600 = 1 hour CacheClockRate 3600 RepeatLimit 32 RewriteRule /robots.txt(.*) /robots.txt$1 [L] RewriteRule /rss.php(.*) /rss.php$1 [L] RewriteRule /tb.php(.*) /tb.php$1 [L] RewriteRule /favicon.ico /favicon.ico [L] RewriteRule /xmlrpc.php(.*) /xmlrpc.php$1 [L] RewriteRule /wlwmanifest.xml /wlwmanifest.xml [L] RewriteRule /(t|m)$ /$1/ [R] RewriteRule /(admin|content|include|t|m)/(.*) /$1/$2 [L] RewriteRule /install.php(.*) /install.php$1 [L] RewriteRule /emlog_toolkit.php(.*) /emlog_toolkit.php$1 [L] RewriteRule /up(d.d.d)to(d.d.d).php(.*) /up$1to$2.php$3 [L] RewriteRule ^/$ /index.php [L] RewriteRule /(.*) /index.php/$1 [L]
RewriteEngine on RewriteBase / RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule .* index.php/$0 [L]
if ('http://' . $_SERVER['HTTP_HOST'] . '/' != BLOG_URL){ header('HTTP/1.1 301 Moved Permanently'); header('Location:' . BLOG_URL . trim(Dispatcher::setPath(), '/')); exit; }
$the_url = Url::log($logid); if (stristr (BLOG_URL . trim(Dispatcher::setPath(), '/'),$the_url) == false){ header('HTTP/1.1 301 Moved Permanently'); header('Location:'.$the_url); exit; }
$the_url = Url::log($logid); if (stristr (BLOG_URL . trim(Dispatcher::setPath(), '/'),$the_url) == false){ header('HTTP/1.1 301 Moved Permanently'); header('Location:'.$the_url); exit; }
$the_url = $_SERVER["REQUEST_URI"]; $the_url = str_replace("index.php","",$the_url); $the_url = str_replace("sort","",$the_url); $the_url = str_replace("/","",$the_url); //通过URL获取到当前日志ID / 别名,找了半天教程都没有、只能用这种旁门左道 $the_url = Url::sort($the_url); if ($the_url != BLOG_URL . trim(Dispatcher::setPath(), '/')){ header('HTTP/1.1 301 Moved Permanently'); header('Location:'.$the_url); exit; }
留言咨询