Skip to content

Instantly share code, notes, and snippets.

@mamor
Created February 11, 2013 07:12
Show Gist options
  • Save mamor/4753075 to your computer and use it in GitHub Desktop.
Save mamor/4753075 to your computer and use it in GitHub Desktop.
.htaccessでスマホをリダイレクトさせるメモ
RewriteEngine On
RewriteBase /xxx
RewriteCond %{HTTP_USER_AGENT} iPod [OR]
RewriteCond %{HTTP_USER_AGENT} iPhone [OR]
RewriteCond %{HTTP_USER_AGENT} iPad [OR]
RewriteCond %{HTTP_USER_AGENT} Android
RewriteRule ^(.*)/yyy/(.*)$ $1/zzz/$2 [R]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment