Home Tutorials Forums Articles Blogs Movies Library Employment Press

Go Back   ActionScript.org Forums > Supporting Technologies > Server-Side Scripting

Reply
 
Thread Tools Rating: Thread Rating: 1 votes, 5.00 average. Display Modes
Old 08-10-2001, 06:33 AM   #1
Redline01
Registered User
 
Join Date: Jun 2001
Location: Corpus Christi, TX, USA
Posts: 14
Lightbulb

Hello All,

I've been working on this for about 2 weeks now. I've spent many many hours on this code. I hope this will benifit some of you. :)

Ok, basically this php file detects the users browser, detects the users screen size, and allows the user to change to a normal exact pixel movie size, or a 100% movie size.

This file is a Flash 5 Script Template. Simply cut and past the into notepad and save it as Detect.phtml, then move the file to the "HTML" folder in your Macromedia Flash 5 Directory on your computer. To publish your movie using this script, go to "Publish Settings". Next select the "Formats" tab, and uncheck "Use default names". Next check the HTML type and place your desired file name with a .phtml extension. Now, go to the "Flash" tab and make sure your movie is set to the desired pixel lenght. Lastly, go to the "HTML" tab select "Detect" under the template pulldown menu.

Ok, after that hopefully un-complcated set-up, we can get down to business:

Code:
$TTDetection
$DS
Detects Browers 4+ and Flash 5 Player
Uses VBScript to detect ActiveX/plug-in
on IE/Navigator 
For Flash 5 only
$DF
<HTML>
<HEAD>
<TITLE>$TI</TITLE>
Ok, I'm going to explain all of the unknown tags for those who aren't familar with Flash Templates.


The above script is is basic information that Flash 5 uses. The $TI is the title of the movie. You can edit the phtml file produced after publishing and change this to whatever you would like your title to be.

Code:
<SCRIPT LANGUAGE=JavaScript>
function SwitchMode()
{
	document.serendipity.SetVariable("skipIntro",1);
}
function SwitchModeOff()
{
	document.serendipity.SetVariable("skipIntro","");
}	
</SCRIPT>
This Javascript sets the variable "skipIntro" to NULL and passes it to the Flash movie, if the user visits the page for the first, or sets it to 1, if the users has returned because they wanted to change the screen size. Basically, if the user visits the page for the fisrt time the sites intro is displayed, but if they pressed the button, inside the Flash movie, to change the movie size, then it skips the intro.

Code:
</HEAD>
<BODY bgcolor="$BG"  marginwidth="0" marginheight="0" leftmargin="0" topmargin="0" rightmargin="0" bottommargin="0">
You can change the body tag to match the colors of your movie.

Code:
<?
echo "<SCRIPT LANGUAGE=JavaScript><!--\n";

if (\$mode == "1")
{
	echo "var smode = 1;";
}
else if (\$mode == "2")
{
	echo "var smode = 2;";
}
else
{
	echo "var smode = 3;";
}
?>
This section is the PHP code that grabs the variable passed in the flash movie to determine what movie sixe the user wants to change to. It detects the variable, then spits out a Javascript varable used later on.

Code:
var plugin = (navigator.mimeTypes && navigator.mimeTypes["application/x-shockwave-flash"]) ? navigator.mimeTypes["application/x-shockwave-flash"].enabledPlugin : 0;
var flashWidth = ($WI / 800) * screen.width;
var flashHeight = ($HE / 800) * screen.width;
flashWidth and flashHeight are a precentage of the screen width and height of the your flash move. 800 is the default screen size tested for my movie. If you use a higher screen resolution, adjust this to your screen width. $WI is the flash movie width and $HE is the flash movie height.

I sugest going here to determine the right screen size for your movie: http://www.turtleshell.com/guide/gen...een/index.html

Code:
var plugin = (navigator.mimeTypes && navigator.mimeTypes["application/x-shockwave-flash"]) ? navigator.mimeTypes["application/x-shockwave-flash"].enabledPlugin : 0;
if ( plugin )
{
	plugin = parseInt(plugin.description.substring(plugin.description.indexOf(".")-1)) >= 5;
}
else if (navigator.userAgent && navigator.userAgent.indexOf("MSIE")>=0 && (navigator.userAgent.indexOf("Windows 95")>=0 || navigator.userAgent.indexOf("Windows 98")>=0 || navigator.userAgent.indexOf("Windows NT")>=0))
{
	document.write("<SCRIPT LANGUAGE=VBScript\> \n");
	document.write("on error resume next \n");
	document.write("plugin = ( IsObject(CreateObject(\"ShockwaveFlash.ShockwaveFlash.5\")))");
	document.write("</SCRIPT\> \n");
}
Ok this detects the browser type and version and whether the user has the Flash 5 Player installed.

Code:
if ( parseInt(navigator.appVersion) < 4 )
{
	document.write("<table width=\"100%\" height=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\"><tr><td align=\"center\" valign=\"middle\"><table height=\"" + flashHeight + "\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" align=\"center\"><tr><td height=\"" + flashHeight + "\" align=\"left\" valign=\"middle\">");
	document.write("<center>");
	document.write("Niether Internet Explorer 4+ nor Nescape Navigator v4+ was detected on your computer.");
	document.write("<br><br>");
	document.write("Please download the recomended browser <a href=\"http://www.microsoft.com/ie\" target=\"_blank\">Microsoft Internet Explorer v5.5+</a>.");
	document.write("<br>");
	document.write("Or download <a href=\"http://www.netscape.com\" target=\"_blank\">Netscape Navigator v4+</a>.");
	document.write("<br><br>");
	document.write("Please download the new version of the <a href=\"http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash\" target=\"_blank\">Flash 5 Player</a> after you download the new browser.");
	document.write("<br><br><br>");
	document.write("</center>");
	document.write("</td></tr></table></td></tr></table>");	
}
This tells the user they should upgrade to a new browser. Feel free to add whatever you want to here. Just make a normal HTML page and add a \ to every ".

Example: "hello" should be \"hello\"

Then add document.write(" to the beginning of each line of code and add "); to the end of each line of code.

Code:
if ( plugin && (smode==1) )
{	
	document.write("<table width=\"100%\" height=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\"><tr><td align=\"center\" valign=\"middle\"><table height=\"" + flashHeight + "\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" align=\"center\"><tr><td height=\"" + flashHeight + "\" align=\"left\" valign=\"middle\">");
	document.write("<OBJECT classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" codebase=\"http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=5,0,0,0\" ID=$TI WIDTH=" + flashWidth + " HEIGHT=" + flashHeight + ">");
	document.write("<PARAM NAME=movie VALUE=\"$TI.swf\">");
	document.write("<PARAM NAME=quality VALUE=$QU>");
	document.write("<PARAM NAME=scale VALUE=exactfit>");
	document.write("<PARAM NAME=bgcolor VALUE=$BG>");
	document.write("<PARAM name=menu value=false>");
	document.write("<EMBED src=\"$TI.swf\" scale=\"exactfit\" quality=$QU bgcolor=$BG swLiveConnect=FALSE WIDTH=" + flashWidth + " HEIGHT=" + flashHeight + " NAME=$TI menu=false TYPE=\"application/x-shockwave-flash\" PLUGINSPAGE=\"http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash\">");
	document.write("</EMBED>");
	document.write("</OBJECT>");
	document.write("</td></tr></table></td></tr></table>");
	SwitchMode();
}
This section writes the <OBJECT> and <EMBED> html tags to the document in normal mode (the exact demension of the flash movie). Then it passes the skipIntro variable to the flash movie inorder for the skip the intro. This script is only accessed if the user pushes the normal mode button. I'll go into this in more detail, at the bottom of the page, after I go over this script. You don't have to change this code. It should work with every movie.

Code:
else if ( plugin && (smode==2) )
{	
	document.write("<OBJECT classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" codebase=\"http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=5,0,0,0\" ID=$TI WIDTH=\"100%\" HEIGHT=\"100%\">");
	document.write("<PARAM NAME=movie VALUE=\"$TI.swf\">");
	document.write("<PARAM NAME=scale VALUE=exactfit>");
	document.write("<PARAM NAME=quality VALUE=$QU>");
	document.write("<PARAM NAME=bgcolor VALUE=$BG>");
	document.write("<PARAM name=menu value=false>");
	document.write("<EMBED src=\"$TI.swf\" scale=\"exactfit\" quality=$QU bgcolor=$BG swLiveConnect=TRUE WIDTH=\"100%\" HEIGHT=\"100%\" NAME=$TI menu=false TYPE=\"application/x-shockwave-flash\" PLUGINSPAGE=\"http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash\">");
	document.write("</EMBED>");
	document.write("</OBJECT>");
	SwitchMode();
}
Same thing as the above section, acept its for fullscreen mode. You don't have to change this either.

Code:
else if ( plugin )
{	
	document.write("<table width=\"100%\" height=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\"><tr><td align=\"center\" valign=\"middle\"><table height=\"" + flashHeight + "\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" align=\"center\"><tr><td height=\"" + flashHeight + "\" align=\"left\" valign=\"middle\">");
	document.write("<OBJECT classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" codebase=\"http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=5,0,0,0\" ID=NAME=$TI WIDTH=" + flashWidth + " HEIGHT=" + flashHeight + ">");
	document.write("<PARAM NAME=movie VALUE=\"serendipity.swf\">");
	document.write("<PARAM NAME=quality VALUE=best>");
	document.write("<PARAM NAME=scale VALUE=exactfit>");
	document.write("<PARAM NAME=bgcolor VALUE=#FFFFFF>");
	document.write("<PARAM name=menu value=false>");
	document.write("<EMBED src=\"serendipity.swf\" scale=\"exactfit\" quality=best bgcolor=#FFFFFF swLiveConnect=true WIDTH=" + flashWidth + " HEIGHT=" + flashHeight + " NAME=$TI menu=\"false\" TYPE=\"application/x-shockwave-flash\" PLUGINSPAGE=\"http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash\">");
	document.write("</EMBED>");
	document.write("</OBJECT>");
	document.write("</td></tr></table></td></tr></table>");
	SwitchModeOff();
}
This section displays the movie in normal mode every time the user first visits the page. No change needed here.

Code:
else
{
	document.write("<table width=\"100%\" height=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\"><tr><td align=\"center\" valign=\"middle\"><table height=\"" + flashHeight + "\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" align=\"center\"><tr><td height=\"" + flashHeight + "\" align=\"left\" valign=\"middle\">");
	document.write("<center>");
	document.write("The Flash 5 Player was not detected on your computer.<br><br>");
	document.write("Please download the new version of the Flash 5 player <a href=\"http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash\" target=\"_blank\">here</a>");
	document.write("<br><br><br>");
	document.write("This site is best viewed with <a href=\"http://www.microsoft.com/ie\" target=\"_blank\">Microsoft Internet Explorer v5.5+</a><br><br><br><br>");
	document.write("<br><br><br>");
	document.write("If you feel you have reached this page in error, <a href=\"flash.html\">click here</a>.");
	document.write("</center>");
	document.write("</td></tr></table></td></tr></table>");
}
This section tells the user he doesn't have the Flash 5 Player Installed. You can modify this section in the same way as you would the code above for the browers detect.

Code:
//-->
</SCRIPT>
</BODY>
</HTML>
Ok now that we have gone over all of that. I'm tired... But, I still have to go over the items needed for the flash movie. Trust me its really fast and simple.

Ok, first go to the first frame of your introduction and insert this script.

Code:
if (skipIntro != "") {
    gotoAndPlay (501);
}
Replace "501" with the first frame number of your content that you want the user to view after the intro. In other words if your movie is set up by having an intro play and then going on to the content of the movie, then you would set "501" to the first frame of that content.

Next, create 2 buttons, one for "Normal" mode and one for "Fullscreen" mode. Add the following actions to each button

Code:
on (release) {
    getURL ("index.phtml?mode=1");
}
Replace "index.phtml" with the name of your published movie .phtml file. Also replace "mode=1" with "mode=2" in your "Fullscreen" button.

Here is the phtml file again without comments.

Code:
$TTDetection
$DS
Detects Browers 4+ and Flash 5 Player
Uses VBScript to detect ActiveX/plug-in
on IE/Navigator 
For Flash 5 only
$DF
<HTML>
<HEAD>
<TITLE>$TI</TITLE>
<SCRIPT LANGUAGE=JavaScript>
function SwitchMode()
{
	document.$TI.SetVariable("skipIntro",1);
}
function SwitchModeOff()
{
	document.$TI.SetVariable("skipIntro","");
}	
</SCRIPT>
</HEAD>
<BODY bgcolor="$BG"  marginwidth="0" marginheight="0" leftmargin="0" topmargin="0" rightmargin="0" bottommargin="0">
<?
echo "<SCRIPT LANGUAGE=JavaScript><!--\n";

if (\$mode == "1")
{
	echo "var smode = 1;";
}
else if (\$mode == "2")
{
	echo "var smode = 2;";
}
else
{
	echo "var smode = 3;";
}
?>

var plugin = (navigator.mimeTypes && navigator.mimeTypes["application/x-shockwave-flash"]) ? navigator.mimeTypes["application/x-shockwave-flash"].enabledPlugin : 0;
var flashWidth = ($WI / 800) * screen.width;
var flashHeight = ($HE / 800) * screen.width;

var plugin = (navigator.mimeTypes && navigator.mimeTypes["application/x-shockwave-flash"]) ? navigator.mimeTypes["application/x-shockwave-flash"].enabledPlugin : 0;
if ( plugin )
{
	plugin = parseInt(plugin.description.substring(plugin.description.indexOf(".")-1)) >= 5;
}
else if (navigator.userAgent && navigator.userAgent.indexOf("MSIE")>=0 && (navigator.userAgent.indexOf("Windows 95")>=0 || navigator.userAgent.indexOf("Windows 98")>=0 || navigator.userAgent.indexOf("Windows NT")>=0))
{
	document.write("<SCRIPT LANGUAGE=VBScript\> \n");
	document.write("on error resume next \n");
	document.write("plugin = ( IsObject(CreateObject(\"ShockwaveFlash.ShockwaveFlash.5\")))");
	document.write("</SCRIPT\> \n");
}
if ( parseInt(navigator.appVersion) < 4 )
{
	document.write("<table width=\"100%\" height=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\"><tr><td align=\"center\" valign=\"middle\"><table height=\"" + flashHeight + "\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" align=\"center\"><tr><td height=\"" + flashHeight + "\" align=\"left\" valign=\"middle\">");
	document.write("<center>");
	document.write("Niether Internet Explorer 4+ nor Nescape Navigator v4+ was detected on your computer.");
	document.write("<br><br>");
	document.write("Please download the recomended browser <a href=\"http://www.microsoft.com/ie\" target=\"_blank\">Microsoft Internet Explorer v5.5+</a>.");
	document.write("<br>");
	document.write("Or download <a href=\"http://www.netscape.com\" target=\"_blank\">Netscape Navigator v4+</a>.");
	document.write("<br><br>");
	document.write("Please download the new version of the <a href=\"http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash\" target=\"_blank\">Flash 5 Player</a> after you download the new browser.");
	document.write("<br><br><br>");
	document.write("</center>");
	document.write("</td></tr></table></td></tr></table>");	
}

if ( plugin && (smode==1) )
{	
	document.write("<table width=\"100%\" height=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\"><tr><td align=\"center\" valign=\"middle\"><table height=\"" + flashHeight + "\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" align=\"center\"><tr><td height=\"" + flashHeight + "\" align=\"left\" valign=\"middle\">");
	document.write("<OBJECT classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" codebase=\"http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=5,0,0,0\" ID=$TI WIDTH=" + flashWidth + " HEIGHT=" + flashHeight + ">");
	document.write("<PARAM NAME=movie VALUE=\"$TI.swf\">");
	document.write("<PARAM NAME=quality VALUE=$QU>");
	document.write("<PARAM NAME=scale VALUE=exactfit>");
	document.write("<PARAM NAME=bgcolor VALUE=$BG>");
	document.write("<PARAM name=menu value=false>");
	document.write("<EMBED src=\"$TI.swf\" scale=\"exactfit\" quality=$QU bgcolor=$BG swLiveConnect=TRUE WIDTH=" + flashWidth + " HEIGHT=" + flashHeight + " NAME=$TI menu=false TYPE=\"application/x-shockwave-flash\" PLUGINSPAGE=\"http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash\">");
	document.write("</EMBED>");
	document.write("</OBJECT>");
	document.write("</td></tr></table></td></tr></table>");
	SwitchMode();
}
else if ( plugin && (smode==2) )
{	
	document.write("<OBJECT classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" codebase=\"http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=5,0,0,0\" ID=$TI WIDTH=\"100%\" HEIGHT=\"100%\">");
	document.write("<PARAM NAME=movie VALUE=\"$TI.swf\">");
	document.write("<PARAM NAME=scale VALUE=exactfit>");
	document.write("<PARAM NAME=quality VALUE=$QU>");
	document.write("<PARAM NAME=bgcolor VALUE=$BG>");
	document.write("<PARAM name=menu value=false>");
	document.write("<EMBED src=\"$TI.swf\" scale=\"exactfit\" quality=$QU bgcolor=$BG swLiveConnect=TRUE WIDTH=\"100%\" HEIGHT=\"100%\" NAME=$TI menu=false TYPE=\"application/x-shockwave-flash\" PLUGINSPAGE=\"http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash\">");
	document.write("</EMBED>");
	document.write("</OBJECT>");
	SwitchMode();
}
else if ( plugin )
{	
	document.write("<table width=\"100%\" height=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\"><tr><td align=\"center\" valign=\"middle\"><table height=\"" + flashHeight + "\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" align=\"center\"><tr><td height=\"" + flashHeight + "\" align=\"left\" valign=\"middle\">");
	document.write("<OBJECT classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" codebase=\"http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=5,0,0,0\" ID=NAME=$TI WIDTH=" + flashWidth + " HEIGHT=" + flashHeight + ">");
	document.write("<PARAM NAME=movie VALUE=\"serendipity.swf\">");
	document.write("<PARAM NAME=quality VALUE=best>");
	document.write("<PARAM NAME=scale VALUE=exactfit>");
	document.write("<PARAM NAME=bgcolor VALUE=#FFFFFF>");
	document.write("<PARAM name=menu value=false>");
	document.write("<EMBED src=\"serendipity.swf\" scale=\"exactfit\" quality=best bgcolor=#FFFFFF swLiveConnect=TRUE WIDTH=" + flashWidth + " HEIGHT=" + flashHeight + " NAME=$TI menu=\"false\" TYPE=\"application/x-shockwave-flash\" PLUGINSPAGE=\"http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash\">");
	document.write("</EMBED>");
	document.write("</OBJECT>");
	document.write("</td></tr></table></td></tr></table>");
	SwitchModeOff();
}
else
{
	document.write("<table width=\"100%\" height=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\"><tr><td align=\"center\" valign=\"middle\"><table height=\"" + flashHeight + "\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" align=\"center\"><tr><td height=\"" + flashHeight + "\" align=\"left\" valign=\"middle\">");
	document.write("<center>");
	document.write("The Flash 5 Player was not detected on your computer.<br><br>");
	document.write("Please download the new version of the Flash 5 player <a href=\"http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash\" target=\"_blank\">here</a>");
	document.write("<br><br><br>");
	document.write("This site is best viewed with <a href=\"http://www.microsoft.com/ie\" target=\"_blank\">Microsoft Internet Explorer v5.5+</a><br><br><br><br>");
	document.write("<br><br><br>");
	document.write("If you feel you have reached this page in error, <a href=\"index.phtml\">click here</a>.");
	document.write("</center>");
	document.write("</td></tr></table></td></tr></table>");
}
//-->
</SCRIPT>
</BODY>
</HTML>
Ok thats it. I hope this helps. Check out my site to view this script in action. http://www.thewebsiteworkshop.com
Redline01 is offline   Reply With Quote
Old 08-10-2001, 03:03 PM   #2
Redline01
Registered User
 
Join Date: Jun 2001
Location: Corpus Christi, TX, USA
Posts: 14
Default

There were a couple of small errors, I didn't catch. Here is the code that actually works.

Code:
$TTDetection
$DS
Detects Browers 4+ and Flash 5 Player
Uses VBScript to detect ActiveX/plug-in
on IE/Navigator 
For Flash 5 only
$DF
<HTML>
<HEAD>
<TITLE>$TI</TITLE>
<SCRIPT LANGUAGE=JavaScript>
function SwitchMode()
{
	document.$TI.SetVariable("skipIntro",1);
}
function SwitchModeOff()
{
	document.$TI.SetVariable("skipIntro","");
}	
</SCRIPT>
</HEAD>
<BODY bgcolor="$BG"  marginwidth="0" marginheight="0" leftmargin="0" topmargin="0" rightmargin="0" bottommargin="0">
<?
echo "<SCRIPT LANGUAGE=JavaScript><!--\n";

if (\$mode == "1")
{
	echo "var smode = 1;";
}
else if (\$mode == "2")
{
	echo "var smode = 2;";
}
else
{
	echo "var smode = 3;";
}
?>

var plugin = (navigator.mimeTypes && navigator.mimeTypes["application/x-shockwave-flash"]) ? navigator.mimeTypes["application/x-shockwave-flash"].enabledPlugin : 0;
var flashWidth = ($WI / 800) * screen.width;
var flashHeight = ($HE / 800) * screen.width;

var plugin = (navigator.mimeTypes && navigator.mimeTypes["application/x-shockwave-flash"]) ? navigator.mimeTypes["application/x-shockwave-flash"].enabledPlugin : 0;
if ( plugin )
{
	plugin = parseInt(plugin.description.substring(plugin.description.indexOf(".")-1)) >= 5;
}
else if (navigator.userAgent && navigator.userAgent.indexOf("MSIE")>=0 && (navigator.userAgent.indexOf("Windows 95")>=0 || navigator.userAgent.indexOf("Windows 98")>=0 || navigator.userAgent.indexOf("Windows NT")>=0))
{
	document.write("<SCRIPT LANGUAGE=VBScript\> \n");
	document.write("on error resume next \n");
	document.write("plugin = ( IsObject(CreateObject(\"ShockwaveFlash.ShockwaveFlash.5\")))");
	document.write("</SCRIPT\> \n");
}
if ( parseInt(navigator.appVersion) < 4 )
{
	document.write("<table width=\"100%\" height=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\"><tr><td align=\"center\" valign=\"middle\"><table height=\"" + flashHeight + "\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" align=\"center\"><tr><td height=\"" + flashHeight + "\" align=\"left\" valign=\"middle\">");
	document.write("<center>");
	document.write("Niether Internet Explorer 4+ nor Nescape Navigator v4+ was detected on your computer.");
	document.write("<br><br>");
	document.write("Please download the recomended browser <a href=\"http://www.microsoft.com/ie\" target=\"_blank\">Microsoft Internet Explorer v5.5+</a>.");
	document.write("<br>");
	document.write("Or download <a href=\"http://www.netscape.com\" target=\"_blank\">Netscape Navigator v4+</a>.");
	document.write("<br><br>");
	document.write("Please download the new version of the <a href=\"http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash\" target=\"_blank\">Flash 5 Player</a> after you download the new browser.");
	document.write("<br><br><br>");
	document.write("</center>");
	document.write("</td></tr></table></td></tr></table>");	
}

if ( plugin && (smode==1) )
{	
	document.write("<table width=\"100%\" height=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\"><tr><td align=\"center\" valign=\"middle\"><table height=\"" + flashHeight + "\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" align=\"center\"><tr><td height=\"" + flashHeight + "\" align=\"left\" valign=\"middle\">");
	document.write("<OBJECT classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" codebase=\"http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=5,0,0,0\" ID=$TI WIDTH=" + flashWidth + " HEIGHT=" + flashHeight + ">");
	document.write("<PARAM NAME=movie VALUE=\"$TI.swf\">");
	document.write("<PARAM NAME=quality VALUE=$QU>");
	document.write("<PARAM NAME=scale VALUE=exactfit>");
	document.write("<PARAM NAME=bgcolor VALUE=$BG>");
	document.write("<PARAM name=menu value=false>");
	document.write("<EMBED src=\"$TI.swf\" scale=\"exactfit\" quality=$QU bgcolor=$BG swLiveConnect=TRUE WIDTH=" + flashWidth + " HEIGHT=" + flashHeight + " NAME=$TI menu=false TYPE=\"application/x-shockwave-flash\" PLUGINSPAGE=\"http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash\">");
	document.write("</EMBED>");
	document.write("</OBJECT>");
	document.write("</td></tr></table></td></tr></table>");
	SwitchMode();
}
else if ( plugin && (smode==2) )
{	
	document.write("<OBJECT classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" codebase=\"http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=5,0,0,0\" ID=$TI WIDTH=\"100%\" HEIGHT=\"100%\">");
	document.write("<PARAM NAME=movie VALUE=\"$TI.swf\">");
	document.write("<PARAM NAME=scale VALUE=exactfit>");
	document.write("<PARAM NAME=quality VALUE=$QU>");
	document.write("<PARAM NAME=bgcolor VALUE=$BG>");
	document.write("<PARAM name=menu value=false>");
	document.write("<EMBED src=\"$TI.swf\" scale=\"exactfit\" quality=$QU bgcolor=$BG swLiveConnect=TRUE WIDTH=\"100%\" HEIGHT=\"100%\" NAME=$TI menu=false TYPE=\"application/x-shockwave-flash\" PLUGINSPAGE=\"http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash\">");
	document.write("</EMBED>");
	document.write("</OBJECT>");
	SwitchMode();
}
else if ( plugin )
{	
	document.write("<table width=\"100%\" height=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\"><tr><td align=\"center\" valign=\"middle\"><table height=\"" + flashHeight + "\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" align=\"center\"><tr><td height=\"" + flashHeight + "\" align=\"left\" valign=\"middle\">");
	document.write("<OBJECT classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" codebase=\"http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=5,0,0,0\" ID=$TI WIDTH=" + flashWidth + " HEIGHT=" + flashHeight + ">");
	document.write("<PARAM NAME=movie VALUE=\"$TI.swf\">");
	document.write("<PARAM NAME=quality VALUE=$QU>");
	document.write("<PARAM NAME=scale VALUE=exactfit>");
	document.write("<PARAM NAME=bgcolor VALUE=$BG>");
	document.write("<PARAM name=menu value=false>");
	document.write("<EMBED src=\"$TI.swf\" scale=\"exactfit\" quality=$QU bgcolor=$BG swLiveConnect=TRUE WIDTH=" + flashWidth + " HEIGHT=" + flashHeight + " NAME=$TI menu=false TYPE=\"application/x-shockwave-flash\" PLUGINSPAGE=\"http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash\">");
	document.write("</EMBED>");
	document.write("</OBJECT>");
	document.write("</td></tr></table></td></tr></table>");
	SwitchModeOff();
}
else
{
	document.write("<table width=\"100%\" height=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\"><tr><td align=\"center\" valign=\"middle\"><table height=\"" + flashHeight + "\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" align=\"center\"><tr><td height=\"" + flashHeight + "\" align=\"left\" valign=\"middle\">");
	document.write("<center>");
	document.write("The Flash 5 Player was not detected on your computer.<br><br>");
	document.write("Please download the new version of the Flash 5 player <a href=\"http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash\" target=\"_blank\">here</a>");
	document.write("<br><br><br>");
	document.write("This site is best viewed with <a href=\"http://www.microsoft.com/ie\" target=\"_blank\">Microsoft Internet Explorer v5.5+</a><br><br><br><br>");
	document.write("<br><br><br>");
	document.write("If you feel you have reached this page in error, <a href=\"index.phtml\">click here</a>.");
	document.write("</center>");
	document.write("</td></tr></table></td></tr></table>");
}
//-->
</SCRIPT>
</BODY>
</HTML>
Redline01 is offline   Reply With Quote
Old 08-11-2001, 01:09 AM   #3
Jesse
ActionScript.org Founder
 
Jesse's Avatar
 
Join Date: Nov 2000
Location: New York
Posts: 8,736
Default

Wow, massive
__________________
Cheers

Jesse Stratford
ActionScript.org Cofounder

Please don't email or PM me Flash questions, that's what the Forums are for!

Please don't rely on me reading my PMs either. Email me about important stuff.
Jesse is offline   Reply With Quote
Reply


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Forum Jump


All times are GMT. The time now is 09:40 PM.

///
Follow actionscriptorg on Twitter

 


Powered by vBulletin® Version 3.8.5
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Ad Management plugin by RedTyger
Copyright 2000-2013 ActionScript.org. All Rights Reserved.
Your use of this site is subject to our Privacy Policy and Terms of Use.