// JavaScript Document

// display random image in corner
//window.onload = swap;
function swap() {
	var numimages=4;
	rndimg = new Array("beach.jpg", "crowd.jpg", "hands.jpg", "skyline1.jpg"); 
	x=(Math.floor(Math.random()*numimages));
	randomimage=(rndimg[x]);
	document.body.style.backgroundImage = "url(http://www.shapish.com/wp-content/themes/simple/bgimgs/"+ randomimage +")"; 
}

// code to insert QT movie
function InsertMovie(url, w, h, autoplay, ctrlr) {
	if (typeof(autoplay) == 'undefined') {autoplay = false}
	if (typeof(ctrlr) == 'undefined') {ctrlr = true}
	document.write('<object classid="clsid:02BF25D5-8C17-4B23-BC80-D3488ABDDC6B" width='+w+' height='+h+' codebase="http://www.apple.com/qtactivex/qtplugin.cab">\n');
	document.write('<param name="src" value='+url+' />\n');
	document.write('<param name="autoplay" value='+autoplay+' />\n');
	document.write('<param name="controller" value='+ctrlr+' />\n');
	document.write('<param name="loop" value="false" />\n');
	document.write('<EMBED src='+url+' width='+w+' height='+h+' autoplay='+autoplay+' controller='+ctrlr+' loop="false" pluginspage="http://www.apple.com/quicktime/download/"></EMBED>\n');
	document.write('</object>\n');
}
