purazumakoiの[はてなブログ]

技術メモから最近はライフログも増えてきてます。

IE6はindex2.htmlを表示、その他はindex.phpを表示

http://exsample.com/
ってなアクセスできた時用

# スパム対策でIE6はindex2.htmlに
RewriteCond %{HTTP_USER_AGENT} "MSIE.6\.0"
RewriteRule ^$ index2.html [L]

# IE6以外はindex.phpを実行となる
RewriteCond %{HTTP_USER_AGENT} !"MSIE.6\.0"
RewriteRule ^$ index.php [L]


ちなみにこれだと
http://exsample.com/index.php
って打たれると出てしまったりする

http://exsample.com/
っていうURLでDos攻撃受けたので、そういうニッチな対策にはなる。