
// DIY Flash/HTML Homepage Highlight script designed to work with Moock detection script 


// In this section we set up the content to be placed dynamically on the page.
// Customize movie tags and alternate html content below.


function writeFeaturedHighlights(){

var baseDir = "http://images.diynet.com/diy_flash/homehighlights/"

if (!useRedirect) {    // if dynamic embedding is turned on
  if(hasRightVersion) {  // if we've detected an acceptable version
        // Dynamically take the variables above, adjust the code below, then write the product on the html page.
        var oeTag = '<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"'
        + 'WIDTH="400" HEIGHT="268"'
        + 'codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=5,0,0,0">'
        + '<PARAM NAME="MOVIE" VALUE="' + baseDir + 'wrapper_100.swf'
		+ '?baseDir=' + baseDir
		+ '&buttonName1=' + buttonName1
		+ '&fileURL1=' + fileURL1
		+ '&redirectURL1=' + redirectURL1
		+ '&buttonName2=' + buttonName2
		+ '&fileURL2=' + fileURL2
		+ '&redirectURL2=' + redirectURL2
		+ '&buttonName3=' + buttonName3
		+ '&fileURL3=' + fileURL3
		+ '&redirectURL3=' + redirectURL3
		+ '">'
      + '<PARAM NAME="QUALITY" VALUE="high">'
      + '<PARAM NAME="AllowScriptAccess" VALUE="always">'
		+ '<param name="wmode" value="opaque">'
        + '<PARAM NAME="MENU" VALUE="false">'
        + '<EMBED SRC="' + baseDir + 'wrapper_100.swf'
		+ '?baseDir=' + baseDir
		+ '&buttonName1=' + buttonName1
		+ '&fileURL1=' + fileURL1
		+ '&redirectURL1=' + redirectURL1
		+ '&buttonName2=' + buttonName2
		+ '&fileURL2=' + fileURL2
		+ '&redirectURL2=' + redirectURL2
		+ '&buttonName3=' + buttonName3
		+ '&fileURL3=' + fileURL3
		+ '&redirectURL3=' + redirectURL3
		+ '" '
        + 'WIDTH="400" HEIGHT="268"'
        + 'QUALITY="high"'
        + 'AllowScriptAccess="always"'
        + 'MENU="false"'
		+ 'wmode="opaque"'
        + 'TYPE="application/x-shockwave-flash"'
        + 'PLUGINSPAGE="http://www.macromedia.com/go/getflashplayer">'
        + '</EMBED>'
        + '</OBJECT>';
        // alert(oeTag);
        document.write(oeTag);   // embed the flash movie

	
  } else {  // flash is too old or we can't detect the plugin
    
var alternateContent = ''
// table with non-flash content
+ '<link href="' + baseDir + 'alternate/style.css" rel="stylesheet" type="text/css">'
+ '<table width="400" height="268" border="0" cellpadding="0" cellspacing="0"><tr><td width="400" height="38"><img src="' + baseDir + 'alternate/title.jpg" width="400" height="38"></td></tr><tr><td width="400" height="204" align="left" valign="middle" background="' + baseDir + 'alternate/bg.gif"><table width="338" border="0" align="center" cellpadding="0" cellspacing="0"><tr><td width="11" align="left" valign="top"><img src="' + baseDir + 'alternate/arrow.gif" width="11" height="16"></td><td width="100%" align="left" valign="top"><span class="altHighHeadline"><a href="'
+ redirectURL1
+ '">'
+ title1
+ '</a></span><br><span class="altHighBody">'
+ description1
+ '</span></td></tr><tr><td colspan="2"><img src="' + baseDir + 'alternate/spacer.gif" width="100" height="10"></td></tr><tr><td align="left" valign="top"><img src="' + baseDir + 'alternate/arrow.gif" width="11" height="16"></td><td align="left" valign="top"><span class="altHighHeadline"><a href="'
+ redirectURL2
+ '">'
+ title2
+ '</a></span><br><span class="altHighBody">'
+ description2
+ '</span></td></tr><tr><td colspan="2"><img src="' + baseDir + 'alternate/spacer.gif" width="100" height="10"></td></tr><tr><td align="left" valign="top"><img src="' + baseDir + 'alternate/arrow.gif" width="11" height="16"></td><td align="left" valign="top"><span class="altHighHeadline"><a href="'
+ redirectURL3
+ '">'
+ title3
+ '</a></span><br><span class="altHighBody">'
+ description3 
+ '</span></td></tr></table></td></tr><tr><td width="400" height="26"><a href="http://www.macromedia.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash" target="_blank"><img src="' + baseDir + 'alternate/getflash.gif" width="400" height="26" border="0"></a></td></tr></table>';
	
document.write(alternateContent);  // insert non-flash content
  }
}
}

var useRedirect = false;
var hasRightVersion = true;

writeFeaturedHighlights();
