Skip to content

Instantly share code, notes, and snippets.

@atypical
Created September 4, 2012 23:21
Show Gist options
  • Save atypical/3627965 to your computer and use it in GitHub Desktop.
Save atypical/3627965 to your computer and use it in GitHub Desktop.
iPhone / iPod / iPad / Android Redirect JS
<script type="text/javascript"> // <![CDATA[
if ((navigator.userAgent.indexOf('iPhone') != -1) || (navigator.userAgent.indexOf('iPod') != -1)) {
document.location = "vx_iphone_experience";
} // ]]>
if ((navigator.userAgent.indexOf('iPad') != -1)) {
document.location = "vx_ipad_experience";
} // ]]>
if ( (navigator.userAgent.indexOf('Android') != -1) ) {
document.location = "vx_iphone_experience";
} // ]]>
</script>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment