Skip to content

Instantly share code, notes, and snippets.

@ArupSen
Last active December 15, 2015 11:38
Show Gist options
  • Select an option

  • Save ArupSen/5254017 to your computer and use it in GitHub Desktop.

Select an option

Save ArupSen/5254017 to your computer and use it in GitHub Desktop.
Is it an iOS device? The iOS sniffer could redirect to a non-flash page or as in the example swap the div containing the flash content with a static image .
<script type="text/javascript" charset="utf-8">
if ((navigator.userAgent.indexOf('iPhone') != -1) || (navigator.userAgent.indexOf('iPod') != -1) || (navigator.userAgent.indexOf('iPad') != -1)) {
// examples
// if you need to add more complex js then of course put this script just above the </body> tag
document.location = "http://sassalina.com/iphone/";
document.getElementById("movie").innerHTML="<img src='http://talismangallery.co.uk/wp-content/uploads/2010/04/talisman-gallery-intro.jpg'>";
}
</script>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment