日期:2014-05-16 浏览次数:21100 次
RewriteEngine On RewriteCond %{HTTP_HOST} !^mangguo.org$ [NC] RewriteRule ^(.*)$ http://mangguo.org/$1 [L,R=301]
RewriteEngine On #将 ?mangguo\.org/ 替换成你的博客地址 RewriteCond %{HTTP_REFERER} !^http://(.+\.)?mangguo\.org/ [NC] RewriteCond %{HTTP_REFERER} !^$ #将 /images/nohotlink.jpg 替换成“请勿盗链”图片地址 RewriteRule .*\.(jpe?g|gif|bmp|png)$ /images/nohotlink.jpg [L]
<IfModule mod_alias.c> RedirectMatch 301 /feed/(atom|rdf|rss|rss2)/?$ http://feeds.telligem.com/flyxiang/ RedirectMatch 301 /comments/feed/(atom|rdf|rss|rss2)/?$ http://feeds.telligem.com/flyxiang/ </IfModule>
ErrorDocument 400 /errors/badrequest.html ErrorDocument 401 /errors/authreqd.html ErrorDocument 403 /errors/forbid.html ErrorDocument 404 /errors/notfound.html ErrorDocument 500 /errors/serverr.html
<Files *.xls> ForceType application/octet-stream Header set Content-Disposition attachment </Files> <Files *.eps> ForceType application/octet-stream Header set Content-Disposition attachment </Files>
# display no errs to user php_flag display_startup_errors off php_flag display_errors off php_flag html_errors off # log to file php_flag log_errors on php_value error_log /location/to/php_error.log
RewriteEngine on RewriteCond %{REQUEST_FILENAME} !-d RewriteCond %{REQUEST_FILENAME}\.html -f RewriteRule ^(.*)$ $1.html # Replace html with your file extension, eg: php, htm, asp
Options -Indexes
AddOutputFilterByType DEFLATE text/html text/plain text/xml application/xml application/xhtml+xml text/javascript text/css application/x-javascript BrowserMatch ^Mozilla/4 gzip-only-text/html BrowserMatch ^Mozilla/4.0[678] no-gzip BrowserMatch bMSIE !no-gzip !gzip-only-text/html
<FilesMatch "\.(htm|html|css|js)$"> AddDefaultCharset UTF-8 </FilesMatch>