/*
YouTube Poster Movie Swapper, version 2008-04-17
Written by David Battino, www.batmosphere.com
Replaces a clicked image with a YouTube movie
OK to use if this notice is included
*/

function viewTube(triggerID,movieURL,movieWth,movieHt) {

	var embedcode = "<object width='" + movieWth + "&autostart=1' height='" + movieHt + "'>";
	embedcode += "<param name='movie' value='" + movieURL + "'></param>";
	embedcode += "<param name='wmode' value='transparent'></param>";
	embedcode += "<embed src='" + movieURL + "&autoplay=1' type='application/x-shockwave-flash' wmode='transparent' width='" + movieWth + "' height='" + movieHt + "'></embed></object>";

temp=navigator.appVersion.split('MSIE');
// Parse the string for the "6" in 6.0
ieVer=parseInt(temp[1]);

if (ieVer == 6) // test for IE 6
{
document.write(getElementById(triggerID).innerHTML=embedcode);
}
else
{
document.getElementById(triggerID).innerHTML=embedcode;
}


  }
