//  _____________________________________________________________________________________________________________
// |_| The Dan Show |____________________________________________________________________________________________|
//
//	atrauzzi@gmail.com
//	(c) 2007 Alexander Trauzzi
//	Any use, modification or derivative works from this script are strictly prohibited unless authorized in
//	writing by the script author.
//
//	This script is used to configure and kickoff the "The Dan Show" site.
//
//	TheDanShow.js has been tested and confirmed to work on the following platforms:
//		Windows			-	Microsoft Internet Explorer 6 32bit
//						Microsoft Internet Explorer 7 32bit
//						Mozilla Firefox 2.0.0.6 32bit
//						Opera 9.22
//						Apple Safari
//		Linux			-	Mozilla Firefox 2.0.0.6 x86
//						Mozilla Firefox 2.0.0.6 x86_64
//						Opera 9.22
//
//	TheDanShow.js depends on:
//		XHTML
//		JavaScript 1.6 with DOM
//		Prototype 1.5.1
//		Scriptaculous 1.7.0
//		ImageRotator by Alexander Trauzzi
//		InnerHTMLPump by Alexander Trauzzi
//  _____________________________________________________________________________________________________________
// |_____________________________________________________________________________________________________________|

// Bind to the window load.
Event.observe(window, "load", function () {

	// This line configures the ImageRotator.
	imageRotator = new ImageRotator($$("#Gallery")[0], "Images/Gallery", 5);
	// Trigger an image load at the start.
	imageRotator.rotate();
	// Start rotating images.
	imageRotator.start();

	// Set up an InnerHTMLPump pointing to the content section.
	contentPump = new InnerHTMLPump($$("#Content")[0]);

	// If we're on Internet Explorer 6.
	if (document.compatMode && document.all && (!window.XMLHttpRequest)) {
		
	  var domTarget = document.body;

		// Remove the PNG image so as not to uglify the site.
		$("Header").style.backgroundImage = "none";

		// Display a warning.
		ie6Warning = document.createElement("div");
		ie6Warning.style.position = "absolute";
		ie6Warning.style.right = "20px";
		ie6Warning.style.top = "20px";
		ie6Warning.style.width = "530px";
		ie6Warning.style.zIndex = "5";
		ie6Warning.style.backgroundColor = "#CCCCCC";
		ie6Warning.style.padding = "9px";
		ie6Warning.style.fontSize = "140%";
		ie6Warning.innerHTML = "You are using Internet Explorer 6<br />To get the best experience, please upgrade your web browser.";
		domTarget.insertBefore(ie6Warning, domTarget.childNodes[0]);

	}

});

//  _____________________________________________________________________________________________________________
// |_____________________________________________________________________________________________________________|
