Results 1 to 1 of 1
Thread: JS redirect ?
Threaded View
-
January 4th, 2006, 06:23 PM #174Registered User
postsJS redirect ?
The code i have so far:
This detects if the user has the proper version of Flash Installed on their comp.Code:<SCRIPT LANGUAGE=JavaScript1.1> <!-- var MM_contentVersion = 7; var plugin = (navigator.mimeTypes && navigator.mimeTypes["application/x-shockwave-flash"]) ? navigator.mimeTypes["application/x-shockwave-flash"].enabledPlugin : 0; if ( plugin ) { var words = navigator.plugins["Shockwave Flash"].description.split(" "); for (var i = 0; i < words.length; ++i) { if (isNaN(parseInt(words[i]))) continue; var MM_PluginVersion = words[i]; } var MM_FlashCanPlay = MM_PluginVersion >= MM_contentVersion; } else if (navigator.userAgent && navigator.userAgent.indexOf("MSIE")>=0 && (navigator.appVersion.indexOf("Win") != -1)) { document.write('<SCR' + 'IPT LANGUAGE=VBScript\> \n'); //FS hide this from IE4.5 Mac by splitting the tag document.write('on error resume next \n'); document.write('MM_FlashCanPlay = ( IsObject(CreateObject("ShockwaveFlash.ShockwaveFlash." & MM_contentVersion)))\n'); document.write('</SCR' + 'IPT\> \n'); } if ( MM_FlashCanPlay ) { window.location.replace("flashindex.html"); } else{ window.location.replace("htmlindex.html"); } //--> </SCRIPT>
I would like to check the users bandwith before I run this check so that if they are on a low speed connection we can just bypass the flash check and send them to the html page. And if they have high speed we can perform the above check.
any suggestions?
Similar Threads
-
detect flash plugin, if no plugin --redirect to non-flash site (javascript)
By JeffFisher in forum Flash IDEReplies: 4Last Post: May 26th, 2009, 03:10 PM -
JS Flash Detection and Redirect
By sigepmest37 in forum Web (HTML5, CSS, JavaScript)Replies: 5Last Post: January 4th, 2006, 09:02 PM -
Redirect Page for Correct Player
By youngloopy in forum Flash IDEReplies: 2Last Post: January 4th, 2006, 12:19 PM -
.HTACCESS redirect file doesn't work with flash site?
By Sany in forum Server-Side (PHP, SQL, ASP.NET, etc.)Replies: 1Last Post: July 3rd, 2004, 08:55 PM -
PHP redirect
By rysolag in forum Server-Side (PHP, SQL, ASP.NET, etc.)Replies: 3Last Post: October 29th, 2003, 08:48 PM

Reply With Quote

Bookmarks