function displayFlash (forceHtml) {

	var theUrl = '/images/poetic.swf?v=3&dir='+document.body.className;

	var theAlt = '/images/poetic.gif';
	var sAlign = 't';
	var theWidth = '860';
	var theHeight = '450';

	if (!forceHtml && flashinstalled == 2 && flashversion >= 8) {

		theHtml  = '<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" ';
		theHtml += 'codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,0,0" ';
		theHtml += 'width="'+theWidth+'" height="'+theHeight+'" id="flash-object">';
		theHtml += '	<param name="allowScriptAccess" value="sameDomain" />';
		theHtml += '	<param name="movie" value="'+theUrl+'" />';
		theHtml += '	<param name="loop" value="true" />';
		theHtml += '	<param name="menu" value="false" />';
		theHtml += '	<param name="quality" value="autohigh" />';
		theHtml += '	<param name="scale" value="noscale" />';
		theHtml += '	<param name="salign" value="'+sAlign+'" />';
		theHtml += '	<param name="wmode" value="transparent" />';
		theHtml += '	<embed src="'+theUrl+'" loop="true" menu="false" quality="autohigh" ';
		theHtml += 'scale="noscale" salign="'+sAlign+'" wmode="transparent" width="'+theWidth+'" height="'+theHeight+'" ';
		theHtml += 'id="flash-embed" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" ';
		theHtml += 'pluginspage="http://www.macromedia.com/go/getflashplayer" />';
		theHtml += '</object>';

	} else {

		theHtml = '<img src="'+theAlt+'" width="'+theWidth+'" height="'+theHeight+'" alt="" />';
		if (document.body.className == 'welcome') {
			theHtml += '<h1><a href="/">Poetic Productions</a></h1>';
		}

	}
	document.getElementById('flash').innerHTML = theHtml;

}

function removeFlash () {
	if (document.getElementById('flash') && navigator.userAgent.indexOf('Firefox') != -1) displayFlash(true);
}

window.addEvent('domready',function(){
		var thisPreload = new Image();
		thisPreload.src = '/images/poetic.gif';
		displayFlash();
	});