+ Reply to Thread
Results 1 to 2 of 2

Obtaining the user's Flash Player version

This is a discussion on Obtaining the user's Flash Player version within the Tutorials forums, part of the Flash English category; An important part of developing a Flash application is to make sure the users can view it. The Flash Player ...

  1. #1
    Administrator Living At The FlepStudio! Flep is on a distinguished road
    Join Date
    Jul 2007
    Posts
    5,762
    Rep Power
    11

    Obtaining the user's Flash Player version

    An important part of developing a Flash application is to make sure the users can view it.
    The Flash Player is in constant development by the owners Adobe, therefore I advise Flash developers to always verify that the users have the correct version installed on their machine.
    There are various ways to do this, but the sure bet is to use the detection kit distributed by Adobe.
    I've personally downloaded it ( here ) and I've personalized it a little.

    Let's see why'

    Usually I apply the following logic to all applications I develop:
    I create an HTML file without SWF in it just to obtain the user's Flash Player version and if valid, I redirect them to the HTML page including the SWF, otherwise I tell the user to update their Flash Player.
    The script that I currently use is the following:
    HTML Code:
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
    <title>main</title>
    <script language="javascript"> DetectFlashVer = 0; </script>
    <script src="http://www.flepstudio.org/forum/tutorials/AC_RunActiveContent.js" language="javascript"></script>
    <script language="JavaScript" type="text/javascript">
    var requiredMajorVersion = 9;
    var requiredMinorVersion = 0;
    var requiredRevision = 45;
    </script>
    </head>
    
    <script language="JavaScript" type="text/javascript">
    var hasRightVersion = DetectFlashVer(requiredMajorVersion, requiredMinorVersion, requiredRevision);
    if(hasRightVersion) 
    {
    		window.location.href = "http://www.miosito.com/paginaflash.html";
    } 
    else 
    {
    	var alternateContent = "Per una corretta visualizzazione, questo sito richiede l' installazione sul tuo PC di Adobe Flash Player "
    			+ '<a href=http://www.adobe.com/shockwave/download/download.cgi'P1_Prod_Version=ShockwaveFlash&Lang=Italian>Installa adesso</a>';
    		document.write(alternateContent);  
    }
    </script>
    <noscript><p>Per una corretta visualizzazione, questo sito richiede l' installazione sul tuo PC di Adobe Flash Player<p><p><p></p>
    <p>  clicca<span class="style1"></span> <a href="http://www.adobe.com/shockwave/download/download.cgi'P1_Prod_Version=ShockwaveFlash&Lang=Italian">Installa adesso</a><p><p><p></p>
    </noscript>
    I usually save it as index.html and I keep it in the folder holding the Flash application on the server.
    This way the user is directed to index.html, which will either re-direct them to the application or show them a warning of the kind:
    This site is best viewed after installation of Adobe Flash Player'etc etc
    Obviously you can personalize it by using simple html.

    For those of you who would like to try/use this script, I remind you to change the following line where the re-direction happens if the version is correct:
    window.location.href = "http://www.mysite.com/flashpage.html";

    Stay tuned !

  2. #2
    Junior Member Settled In shyraza is on a distinguished road
    Join Date
    Mar 2009
    Posts
    2
    Rep Power
    0

    Re: Obtaining the user's Flash Player version

    plz can u make a fla or a simple for it plz

+ Reply to Thread

Similar Threads

  1. Events Scroller - version 2
    By Flep in forum FlepStudio utilities
    Replies: 25
    Last Post: 27-02-11, 15:49
  2. CountDown version 2
    By Flep in forum FlepStudio utilities
    Replies: 7
    Last Post: 03-12-10, 02:23
  3. Images Scroller version 2
    By Flep in forum FlepStudio utilities
    Replies: 3
    Last Post: 03-08-10, 18:49
  4. Quizzer version 2
    By Flep in forum FlepStudio utilities
    Replies: 3
    Last Post: 26-05-10, 18:40
  5. Events Scroller - version 3
    By Flep in forum FlepStudio utilities
    Replies: 8
    Last Post: 08-04-10, 18:04

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts