var InSubDir; InSubDir=0;
var RingOn; RingOn=0;
function beginBody(atx) {
//  drawName(atx);
  BuildPage();
//  drawBar(atx);
}
//document.writeln('<TABLE BORDER=4 WIDTH="100%" cellpadding=4 cellspacing=0 bordercolor="#008AFB" bordercolorlight="#008AFB"><TR><TD VALIGN=TOP>'); }
function drawName(atx) {
  document.writeln('<FONT FACE=Arial><B><I><font size=5 color="#000000">HR-Survey.</font>')
  document.writeln('<font size=5 color="#FF0000">Com</font>')
  document.writeln('<font size=3 color="#000000"> </font>')
  document.writeln('&nbsp;&nbsp;&nbsp;<font size=5 color="#000000">Web-Based Surveys</font>');
  document.writeln('</I></B><font size=5><br clear=all></font>')
}
function mOvr(src,clrOver) { if (!src.contains(event.fromElement)) { src.bgColor = clrOver; }}
function mOut(src,clrIn) { if (!src.contains(event.toElement)) { src.bgColor = clrIn; }} 
function drawBar(atx) {
  document.writeln('<STYLE TYPE="text/css">')
  document.writeln('  A:link {text-decoration:underline;color:0000FF;font-family: arial, helvetica; font-size: 12px; font-weight:normal}')
  document.writeln('  A:hover{text-decoration:none;color:FF4444;font-family: arial, helvetica; font-size: 12px; font-weight:normal}')
  document.writeln('  A:active{text-decoration:underline;color:0000FF;font-family: arial, helvetica; font-size: 12px; font-weight:normal}')
  document.writeln('  A:visited{text-decoration:underline;color:0000FF;font-family: arial, helvetica; font-size: 12px; font-weight:normal}')
  document.writeln('</STYLE>')
  document.writeln('<A HREF="http://www.hr-survey.com/surveys.html" >Surveys</A>, <A HREF="http://www.hr-survey.com/WebTechnology.htm" >Web</A>, <A HREF="http://www.hr-survey.com/SurveyDemos.htm" >Demos</A> |')
  document.writeln('<A HREF="http://www.hr-software.net" >HR-Software.net</A> |')
  document.writeln('<A HREF="http://www.hr-guide.com/" >HR-Guide.com</A> |')
  document.writeln('<A HREF="http://www.hr-survey.com/" >HR-Survey.com</a><BR>')
}
function footer() { 
  document.writeln('<br><br><HR>')
  document.writeln('<center>Need more information? Email the: <a href="mailto:webmaster@hr-guide.com">webmaster</a>.<BR>')
  document.writeln('<BR><BR><BR>')
  document.writeln('<Img src="http://www.hr-guide.com/images/hr-ringa.gif" border=0 height=47 width=100 onClick="if(RingOn==0){RingOn=1;}else{RingOn=0;}">')
  document.writeln('</center><BR>')
  document.write('</td></tr></table>')
  document.write('</td></tr></table>')
}
function CheckLogin() { 
  if ((document.dataform.UserName.value != '') && (document.dataform.Password.value != '')){
    document.dataform.action='http://'+document.dataform.UserName.value+':'+document.dataform.Password.value+'@'+'www.hr-survey.com/users/login.cgi';
    document.href=document.dataform.action
    return true;
  } else {
    alert('Please fill both Username and password in order to logon');
    return false;        
  }
}
function GetWidth() { return 150; }
function ShowLogo() {
  var MyWidth;
  MyWidth=GetWidth();
  document.write('<table width='+MyWidth+' cellspacing=0 cellpadding=0 border=0>')
  document.write('<tr><td bgcolor="#000000">')
  document.write('   <table width="'+MyWidth+'" border="0" cellspacing="0" cellpadding="3" align=center>')
  document.write('   <tr><td valign=top width='+(MyWidth-22)+'>')
  document.write('<font face="verdana,arial" size=3 color="#ffffff"><B>')
  document.write('HR-Consultant')
  document.write('<font size=1>')
  document.write('.net')
  document.write('</font></font></b>')
  document.write('   </td></tr>')
  document.write('   </table>')
  document.write('</td></tr></table>')
}
function ImRoot() {
  if(InSubDir==1) return "../images/"; return "http://www.hr-guide.com/images/";
}
function ShowNews() {
  var MyWidth;  MyWidth=GetWidth();
  document.write('<table width='+MyWidth+' cellspacing=0 cellpadding=0 border=0>')
  document.write('<tr><td bgcolor="#cfcfcf"><Font Size=1>')
  document.write('News from ZDNet<BR>')
  ShowZDNews()
  document.write('</font></td></tr></table>')
}
function ShowJoin(URL) {
  var MyWidth;
  MyWidth=GetWidth();
  document.write('<table width="'+MyWidth+'" border="0" cellspacing="0" cellpadding="6"><tr>')
  document.write('<td width="'+MyWidth+'" bgcolor="#f5f5f5" valign="top">')
  document.write('  <font face="verdana,arial" size=2>Request Account</font><BR>')
  document.write('  <table border="0" cellpadding="0" cellspacing="0" width="'+(MyWidth-12)+'"><tr>')
  document.write('    <td valign="top" width="8"><font face="arial, helvetica" size="-2" class="body" color="#669900"><font color="#669900">&#149;</font></font></td>')
  document.write('    <td valign="top" width="'+(MyWidth-12)+'"><font face="Arial, helvetica" size="-2" class="body">100% Web Based</td><tr>')
  document.write('<tr><td valign="top" width="8"><font face="arial, helvetica" size="-2" class="body"><font color="#669900">&#149;</font></font></td>')
  document.write('<td valign="top" width="'+(MyWidth-12)+'"><font face="Arial, helvetica" size="-2" class="body">Access to your data 24/7</font></td></tr>')
  document.write('<tr><td valign="top" width="8"><font face="arial, helvetica" size="-2" class="body" color="#669900"><font color="#669900">&#149;</font></font></td>')
  document.write('<td valign="top" width="'+(MyWidth-12)+'"><font face="Arial, helvetica" size="-2" class="body">Built on fast SQL</font></td></tr>')
  document.write('<tr><td valign="top" width="8"><font face="arial, helvetica" size="-2" class="body" color="#669900"><font color="#669900">&#149;</font></font></td>')
  document.write('<td valign="top" width="'+(MyWidth-12)+'"><font face="Arial, helvetica" size="-2" class="body">More</font></td></tr>')
  document.write('</table>')
  document.write('<a href="'+URL+'"><img src="'+ImRoot()+'join_now.gif" vspace="5" border="0" WIDTH="78" HEIGHT="17"></a>')
  document.write('<BR></td></tr></table>')
}
function ShowHeader(Label,URL) {
  var MyWidth;
  MyWidth=GetWidth();
  document.write('<table width="'+MyWidth+'" border="0" cellspacing="0" cellpadding="0"><tr>')
  document.write('<td width="13" bgcolor="#999999"><img src="'+ImRoot()+'sm_gray_button.gif" width=13 height=13 border=0 alt="Demos"></td>')
  document.write('<td width="4" bgcolor="#999999"><img src="'+ImRoot()+'transpacer.gif" width="2" height="1" border="0"></td>')
  document.write('<td bgcolor="#999999"><font face="arial, helvetica" size="-1" color="#ffffff" class="bar"><b>'+Label+'</b></font></td>')
  document.write('</tr></table>')
}
function ShowBBar(Label) {
  var MyWidth;
  MyWidth=GetWidth();
  document.write('<table width="'+MyWidth+'" border="0" cellspacing="0" cellpadding="0">')
  document.write('<tr height=1><td bgcolor="#F1F1F1" width=1><img src="'+ImRoot()+'transpacer.gif" width="1" height="1" border="0"></td>')
  document.write('<td bgcolor="#ECECEC"><img src="'+ImRoot()+'transpacer.gif" width="'+(MyWidth-2)+'" height="1" border="0"></td>')
  document.write('<td bgcolor="#DDDDDD" width=1><img src="'+ImRoot()+'transpacer.gif" width="1" height="1" border="0"></td></tr>')
  document.write('<tr ><td bgcolor="#ECECEC" width=1><img src="'+ImRoot()+'transpacer.gif" width="1" border="0"></td>')
  document.write('<td bgcolor="#E2E2E2" valign=center><img src="'+ImRoot()+'md_gray_button.gif" width="17" height="17" border="0">')
  document.write('<font face="verdana,arial" size=2>'+Label+'</font></td>')
  document.write('<td bgcolor="#B9B9B9" width=1><img src="'+ImRoot()+'transpacer.gif" width="1" height="1" border="0"></td></tr>')
  document.write('<tr height=1><td bgcolor="#E0E0E0" width=1><img src="'+ImRoot()+'transpacer.gif" width="1" height="1" border="0"></td>')
  document.write('<td bgcolor="#B9B9B9"><img src="'+ImRoot()+'transpacer.gif" width="'+(MyWidth-2)+'" height="1" border="0"></td>')
  document.write('<td bgcolor="#AFAFAF" width=1><img src="'+ImRoot()+'transpacer.gif" width="1" height="1" border="0"></td></tr>')
  document.write('</table>')
}
function ShowRing() {
  document.writeln('<TABLE BORDER=0 cellpadding=0 cellspacing=0 width="100%"><TR height="15" bgcolor="#AAffff"><td>')
  document.writeln('<TABLE BORDER=0 cellpadding=3 cellspacing=0><TR height="15" bgcolor="#AAffff">')
  document.writeln('<TD VALIGN=center ><font face="verdana,arial" size=2>Part of the <i>HR Ring</i>.</TD><TH>|</TH>')
  document.writeln('<TH VALIGN=center ><A HREF="http://www.hr-guide.com/compensation.htm" CLASS="D">Compensation</A></TH><TH>|</TH>')
  document.writeln('<TH VALIGN=center ><A HREF="http://www.hr-software.net" CLASS="D">Software</A></TH><TH>|</TH>')
  document.writeln('<TH VALIGN=center ><A HREF="http://www.hr-survey.com" CLASS="D">Surveys</A></TH><TH>|</TH>')
  document.writeln('<TH VALIGN=center ><A HREF="http://www.hr-guide.com/indexDocs.html" CLASS="D">Documents</A></TH><TH>|</TH>')
  document.writeln('<TH VALIGN=center ><A HREF="http://www.job-analysis.net" CLASS="D">Job Analysis</A></TH><TH>|</TH>')
  document.writeln('<TD VALIGN=TOP bgcolor="#008AFB">&nbsp;</TD>')
  document.writeln('</TR></TABLE>')
  document.writeln('</TD></TR></TABLE>')
}

function ShowSoft(MyClass,WidthOverride) {
  var SpecClass;
  SpecClass=''
  if(MyClass.indexOf("E") >= 0) { SpecClass='CLASS="E"'; }
  var MyWidth;
  MyWidth=GetWidth();
  if(WidthOverride > MyWidth) MyWidth=WidthOverride;
var Demos
var b
b=0
Demos = new Array();
Demos[b++]=new Array('EEO','',1);
Demos[b++]=new Array('Disparate Impact Analysis','http://www.hr-software.net/EmploymentStatistics/DisparateImpact.htm',0);
Demos[b++]=new Array('Utilization Analysis','http://www.hr-software.net/EmploymentStatistics/UtilizationAnalysis.htm',0);
Demos[b++]=new Array('Testing','',1);
Demos[b++]=new Array('Item Analysis','http://www.hr-software.net/cgi/ItemAnalysis.cgi',0);
Demos[b++]=new Array('Theoretical Expectancy Calculator','http://www.acd.ccac.edu/hr/EmploymentStatistics/TheoreticalExpectancy/Calculator.cgi',0);
Demos[b++]=new Array('Job Analysis','',1);
Demos[b++]=new Array('Create an On-line Position Description Questionnaire','http://www.hr-guide.com/data/G908.htm',0);
Demos[b++]=new Array('On-Line Action Verbs','http://www.hr-guide.com/data/G053.htm',0);
Demos[b++]=new Array('Job Evaluation','',1);
Demos[b++]=new Array('Ranking Method','http://www.hr-guide.com/data/G909.htm',0);
Demos[b++]=new Array('Point Method','http://www.hr-software.net/cgi/JobEvaluation.cgi',0);
Demos[b++]=new Array('Surveys','',1);
Demos[b++]=new Array('Salary Survey','http://www.hr-survey.com/SalarySurvey.htm',0);
Demos[b++]=new Array('Employee Attitude','http://www.hr-survey.com/',0);
Demos[b++]=new Array('Compensation','',1);
Demos[b++]=new Array('Wage/Hour Conversion Calculator','http://www.hr-guide.com/data/G917.htm',0);
Demos[b++]=new Array('Tax Withholding Calculator','http://www.pensoft.com/payroll_information/t_taxcalc.html',0);
Demos[b++]=new Array('Cost of Turnover Calculators','http://www.hr-software.net/pages/220.htm',0);
//Demos[b++]=new Array('','',0);
  document.write('<table width="'+MyWidth+'" border="0" cellspacing="0" cellpadding="6"><tr>')
  document.write('<td width="'+MyWidth+'" bgcolor="#f5f5f5" valign="top">')
//  document.write('  <font face="verdana,arial" size=2>Demos</font><BR>')
  document.write('  <table border="0" cellpadding="0" cellspacing="0" width="'+(MyWidth-12)+'">')
  for(i=0;i<b;i++) {
    document.write('<tr>')
    if(Demos[i][2]==1) {
      document.write('<td valign="top" COLSPAN=2><font face="Arial, helvetica" size="-2" class="body">')
      document.write(Demos[i][0]+'</td></tr>')
    } else {
      document.write('    <td valign="top" width="8"><font face="arial, helvetica" size="-2" class="body" color="#669900"><font color="#669900">&#149;</font></font></td>')
      document.write('    <td valign="top" width="'+(MyWidth-12)+'"><font face="Arial, helvetica" size="-2" class="body">')
      document.write('<a href="'+Demos[i][1]+'" ' + SpecClass +'>')
      document.write(Demos[i][0]+'</a></td></tr>')
    }
  }
  document.write('</table>')
  document.write('</td></tr></table>')
}
function ShowCats() {
  var MyWidth;  MyWidth=GetWidth();
  document.write('<table width='+MyWidth+' cellspacing=0 cellpadding=0 border=0>')
  document.write('<tr><td bgcolor="#cfcfcf"><Font Size=1>')
var SpecClass
SpecClass=''
var Demos
var b
b=0
Demos = new Array();
Demos[b++]=new Array('360 Feedback','http://www.hr-software.net/pages/215.htm',0);
Demos[b++]=new Array('Applicant Tracking','http://www.hr-software.net/pages/201.htm',0);
Demos[b++]=new Array('Compensation Admin','http://www.hr-software.net/pages/203.htm',0);
Demos[b++]=new Array('HRIS','http://www.hr-software.net/pages/206.htm',0);
Demos[b++]=new Array('Int. Voice Resp.','http://www.hr-software.net/pages/216.htm',0);
Demos[b++]=new Array('Intranets','http://www.hr-software.net/pages/012.htm',0);
Demos[b++]=new Array('Payroll','http://www.hr-software.net/pages/213.htm',0);
Demos[b++]=new Array('Personnel Scheduling','http://www.hr-software.net/pages/217.htm',0);
Demos[b++]=new Array('Time and Attendance','http://www.hr-software.net/pages/211.htm',0);
Demos[b++]=new Array('Benefits Admin','http://www.hr-software.net/pages/202.htm',0);
Demos[b++]=new Array('EEO Compliance','http://www.hr-software.net/pages/204.htm',0);
Demos[b++]=new Array('Surveys/Feedback','http://www.hr-software.net/pages/205.htm',0);
Demos[b++]=new Array('Emp. Self Serve','http://www.hr-software.net/pages/212.htm',0);
Demos[b++]=new Array('Job Posting','http://www.hr-software.net/pages/208.htm',0);
Demos[b++]=new Array('Org Charts','http://www.hr-software.net/pages/214.htm',0);
Demos[b++]=new Array('Testing/Selection','http://www.hr-software.net/pages/210.htm',0);
Demos[b++]=new Array('Performance Appraisal','http://www.hr-software.net/pages/209.htm',0);
Demos[b++]=new Array('Trng and Development','http://www.hr-software.net/pages/218.htm',0);
  document.write('<table border="0" cellpadding="0" cellspacing="0" width="'+(MyWidth-12)+'">')
  for(i=0;i<b;i++) {
    document.write('<tr>')
      document.write('    <td valign="top" width="8"><font face="arial, helvetica" size="-2" class="body" color="#669900"><font color="#669900">&#149;</font></font></td>')
      document.write('    <td valign="top" width="'+(MyWidth-12)+'"><font face="Arial, helvetica" size="-2" class="body">')
      document.write('<a href="'+Demos[i][1]+'" ' + SpecClass +'>')
      document.write(Demos[i][0]+'</a></td></tr>')
  }
  document.write('</table>')
  document.write('</font></td></tr></table>')
}
function ShowMesg(MyMsg,WidthOverride) {
  var MyWidth;
  MyWidth=GetWidth();
  if(WidthOverride > MyWidth) MyWidth=WidthOverride;
  document.write('<table width="'+MyWidth+'" border="0" cellspacing="0" cellpadding="6"><tr>')
  document.write('<td width="'+MyWidth+'" bgcolor="#d5d5d5" valign="top">')
  document.write(MyMsg)
  document.write('</td></tr></table>')
}
function BuildPage() {
  var MyWidth;
  MyWidth=GetWidth();
  document.write('<table border=0 width="100%" cellpadding=0 cellspacing=0><tr>')
  document.write('<td width="'+MyWidth+'" bgcolor="#bfe88f" valign="top">')
  ShowLogo()
  document.write('</td><td valign=top>')
  ShowRing()
  document.write('</td></tr><tr><td valign=top>')
  ShowBBar(' Search ')
  ThisMsg='<form action=http://www.hr-guide.com/cgi-local/search.cgi><input type=text size=12 name=q><input type=submit value=Find class=button></form>'
  ShowMesg(ThisMsg,0)
  ShowBBar('<a href=http://www.hr-guide.com/selection.htm CLASS="C">Selection/Staffing</a>')
  ShowBBar('<a href=http://www.hr-guide.com/compensation.htm CLASS="C">Compensation</a>')
  ShowBBar('<a href=http://www.hr-software.net CLASS="C">Software</a>')
  ShowBBar('<a href=http://www.job-analysis.net CLASS="C">Job Analysis</a>')
  ShowBBar('Featured Website')
  ThisMsg=''
  ThisMsg+='<br><a href="http://www.hr-survey.com/adeo.htm" target="_new"><font size=-1>hr-survey.com</A>'
  ThisMsg+='<BR>Customized survey solutions to meet your needs. Connecting you with your employees. Online survey and real-time results.'
  ThisMsg+='</font>'
  ShowMesg(ThisMsg,0)
  ShowBBar('<a href="http://www.hr-guide.com/mediakit/aboutus.htm" CLASS="C">About Us</a>')
  ShowBBar('<a href="http://www.hr-guide.com/comment.htm" CLASS="C">Feedback/<br>&nbsp;Comments?</a>')
  ShowBBar('<a href="http://www.hr-guide.com/mediakit/" CLASS="C">Advertise</a>')
  document.write('</td><td valign=top>')
  document.write('<table border=0 width="100%" cellpadding=2 cellspacing=0><tr><td>')
}

function beginGBody() {
  var MyWidth;
  MyWidth=GetWidth();
  document.write('<TABLE BORDER=0 cellpadding=0 cellspacing=0 width="100%"><TR height="15">')
  document.write('<TD VALIGN=TOP bgcolor="#008AFB">')
  document.write('<style type="text/css" class="ts"><!--')
  document.write('A.B { TEXT-DECORATION: none; COLOR:#FFFFFF }')
  document.write('A.B:hover { COLOR: #000000 }')
  document.write('//--></style>')
  document.write('<TABLE BORDER=0 cellpadding=1 cellspacing=1><TR height="15">')
  document.write('<TH>HR-Guide.Com</TH><TH>|</TH>')
  document.write('<TH VALIGN=center onmouseover="mOvr(this,\'#FFFFFF\');" onmouseout="mOut(this,\'#008AFB\');"><A HREF="http://www.hr-consultant.net" CLASS="B">Consultants</A></TH><TH>|</TH>')
  document.write('<TH VALIGN=center onmouseover="mOvr(this,\'#FFFFFF\');" onmouseout="mOut(this,\'#008AFB\');"><A HREF="http://www.hr-software.net" CLASS="B">Software</A></TH><TH>|</TH>')
  document.write('<TH VALIGN=center onmouseover="mOvr(this,\'#FFFFFF\');" onmouseout="mOut(this,\'#008AFB\');"><A HREF="http://www.hr-guide.com/indexDocs.html" CLASS="B">Documents</A></TH><TH>|</TH>')
  document.write('<TH VALIGN=center onmouseover="mOvr(this,\'#FFFFFF\');" onmouseout="mOut(this,\'#008AFB\');"><A HREF="http://www.hr-guide.com/" CLASS="B">HR Guides</A></TH><TH>|</TH>')
  document.write('<TD VALIGN=TOP bgcolor="#008AFB">&nbsp;</TD>')
  document.write('</TR></TABLE>')
  document.write('</TD></TR></TABLE>')
  document.write('<TABLE BORDER=4 WIDTH="100%" cellpadding=4 cellspacing=0 bordercolor="#008AFB" bordercolorlight="#008AFB"><TR><TD VALIGN=TOP>')
}

function beginPBody() {
  var MyWidth;
  MyWidth=GetWidth();
  document.write('<table border=0 width="100%" cellpadding=0 cellspacing=0><tr>')
  document.write('<td width="'+MyWidth+'" bgcolor="#bfe88f" valign="top">')
  ShowLogo()
  document.write('</td><td valign=top>')
  ShowRing()
  document.write('</td></tr></table>')
  document.write('<table border=0 width="'+MyWidth+'" cellpadding=0 cellspacing=0 align=left><tr><td valign=top width="'+MyWidth+'" >')
  ShowBBar('Categories')
  ShowCats()
  ShowBBar('Free HR Software')
  ShowSoft("0",0)
  document.write('</td></tr></table>')
}


// ***************************************************************
// Detect Flash

var requiredVersion = 4;   // version the user needs to view site (max is 5, min is 2)
var useRedirect = false;    // "true" loads new flash or non-flash page into browser
         // "false" embeds movie or alternate html code into current page

var flashPage = "movie.html"  // the location of the flash movie page
var noFlashPage = "noflash.html" // send user here if they don't have the plugin or we can't detect it
var upgradePage = "upgrade.html" // send user here if we detect an old plugin

// system globals
var flash2Installed = false;  // boolean. true if flash 2 is installed
var flash3Installed = false;  // boolean. true if flash 3 is installed
var flash4Installed = false;  // boolean. true if flash 4 is installed
var flash5Installed = false;  // boolean. true if flash 5 is installed
var maxVersion = 5;     // highest version we can actually detect
var actualVersion = 0;    // version the user really has
var hasRightVersion = false;  // boolean. true if it's safe to embed the flash movie in the page
var jsVersion = 1.0;    // the version of javascript supported

// check the browser...we're looking for ie/win
var isIE = (navigator.appVersion.indexOf("MSIE") != -1) ? true : false;  // true if we're on ie
var isWin = (navigator.appVersion.indexOf("Windows") != -1) ? true : false; // true if we're on windows

// this is a js1.1 code block, so make note that js1.1 is supported.
jsVersion = 1.1;

// write vbscript detection if we're not on mac.
if(isIE && isWin){ // don't write vbscript tags on anything but ie win
 document.write('<SCR' + 'IPT LANGUAGE=VBScript\> \n');
 document.write('on error resume next \n');
 document.write('flash2Installed = (IsObject(CreateObject("ShockwaveFlash.ShockwaveFlash.2"))) \n');
 document.write('flash3Installed = (IsObject(CreateObject("ShockwaveFlash.ShockwaveFlash.3"))) \n');
 document.write('flash4Installed = (IsObject(CreateObject("ShockwaveFlash.ShockwaveFlash.4"))) \n');
 document.write('flash5Installed = (IsObject(CreateObject("ShockwaveFlash.ShockwaveFlash.5"))) \n'); 
 document.write('</SCR' + 'IPT\> \n'); // break up end tag so it doesn't end our script
}

// next comes the standard javascript detection that uses the navigator.plugins array
// we pack the detector into a function so it loads before we run it

function detectFlash(){ 

 if (navigator.plugins){        // does navigator.plugins exist?
  if (navigator.plugins["Shockwave Flash 2.0"]  // yes>> then is Flash 2 
  || navigator.plugins["Shockwave Flash"]){  // or flash 3+ installed?

   // set convenient references to flash 2 and the plugin description
   var isVersion2 = navigator.plugins["Shockwave Flash 2.0"] ? " 2.0" : "";
   var flashDescription = navigator.plugins["Shockwave Flash" + isVersion2].description;
   // a flash plugin-description looks like this: Shockwave Flash 4.0 r5
   // so we can get the major version by grabbing the character before the period
   // note that we don't bother with minor version detection. do that in your movie with $version
   var flashVersion = parseInt(flashDescription.charAt(flashDescription.indexOf(".") - 1));

   // we know the version, now set appropriate version flags
   flash2Installed = flashVersion == 2;  
   flash3Installed = flashVersion == 3;
   flash4Installed = flashVersion == 4;
   flash5Installed = flashVersion == 5;
  }
 }
 
 // loop through all versions we're checking, and set actualVersion to highest detected version
 for (var i = 2; i <= maxVersion; i++) { 
  if (eval("flash" + i + "Installed") == true) actualVersion = i;
 }
 // if we're on webtv, the version supported is 2 (pre-summer2000, or 3, post-summer2000)
 // note that we don't bother sniffing varieties of webtv. you could if you were sadistic...
 if(navigator.userAgent.indexOf("WebTV") != -1) actualVersion = 2; 
 
 // uncomment next line to display flash version during testing
   
   <!-- alert("version detected: " + actualVersion); -->


 // we're finished getting the version. time to take the appropriate action

 if (actualVersion >= requiredVersion) {   // user has a new enough version
  hasRightVersion = true;      // flag: it's okay to write out the object/embed tags later

  if (useRedirect) {       // if the redirection option is on, load the flash page
   if(jsVersion > 1.0) {     // need javascript1.1 to do location.replace
    window.location.replace(flashPage); // use replace() so we don't break the back button
   } else {
    window.location = flashPage;  // otherwise, use .location
   }
  }
 } else { // user doesn't have a new enough version.
 
  if (useRedirect) {  // if the redirection option is on, load the appropriate alternate page
   if(jsVersion > 1.0) { // need javascript1.1 to do location.replace
    window.location.replace((actualVersion >= 2) ? upgradePage : noFlashPage);
   } else {
    window.location = (actualVersion >= 2) ? upgradePage : noFlashPage;
   }
  }
 }
}


detectFlash(); // call our detector now that it's safely loaded. 

function ShowFlash(MyFlash,MyWidth,MyHeight) {
  var oeTags = '<OBJECT CLASSID="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"'
  + 'WIDTH="'+MyWidth+'" HEIGHT="'+MyHeight+'"'
  + 'CODEBASE="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab">'
  + '<PARAM NAME="MOVIE" VALUE="'+MyFlash+'">'
  + '<PARAM NAME="PLAY" VALUE="true">'
  + '<PARAM NAME="LOOP" VALUE="true">'
  + '<PARAM NAME="QUALITY" VALUE="high">'
  + '<PARAM NAME="MENU" VALUE="false">'
  + '<EMBED SRC="'+MyFlash+'"'
  + 'WIDTH="'+MyWidth+'" HEIGHT="'+MyHeight+'"'
  + 'PLAY="true"'
  + 'LOOP="true"'
  + 'QUALITY="high"'
  + 'MENU="false"'
  + 'TYPE="application/x-shockwave-flash"'
  + 'PLUGINSPAGE="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash">'
  + '</EMBED>'
  + '</OBJECT>';
  document.write(oeTags);  // embed the flash movie
}

