
function checkJQuery()
{
	// Hrm, still not loaded. Wait a half sec and check again
	if ((typeof jQuery == 'undefined') || (jQuery == null)) 
		setTimeout("self.checkJQuery()", 500);
	else
		$(document).ready(function() { excuseMeIE(); });
}

function youAreExcused()
{
	$('#excuseMeDiv').fadeOut("slow", function() { $('#excuseMeDiv').remove() });
}

function excuseMeIE()
{
	var div = document.createElement("div");
	div.id = "excuseMeDiv";
	document.body.appendChild(div);
	div = $('#excuseMeDiv');
	div.hide();
	div.css(
		{
			"background-color":"#CFCFCF",
			"font":"normal 9px/12px Verdana",
			"padding":"3px",
			"min-height":"20px",
			"position":"fixed",
			"top":"0px",
			"left":"0px",
			"width":"100%",
			"text-align":"center",
			"color":"black",
			"border":"1px solid black"
		});
	div.html("<div>Hi! We noticed you're using Internet Explorer. Did you know there are much better web browsers out there? <a href='http://getfirefox.net'>Mozilla FireFox</a>, <a href='http://www.google.com/chrome'>Google Chrome</a>, or <a href='http://www.apple.com/safari/download/'>Apple Safari</a> are great web browsers. All of them are free and generally provide a superior browsing experience over Internet Explorer. This isn't an advertisement or anything, we just wanted to let you know.</div><div style='float: right'><button onclick='youAreExcused()'>Close</a></div>");
	div.slideDown(1000);
	setTimeout("self.youAreExcused()", 20 * 1000);
}

if (/MSIE (\d+\.\d+);/.test(navigator.userAgent))
{
	// detect jQuery
	if ((typeof jQuery == 'undefined') || (jQuery == null)) 
	{
		var s = document.createElement( 'script' );
        s.type ='text/javascript';
        s.src = 'http://jqueryjs.googlecode.com/files/jquery-1.3.2.min.js';
        document.getElementsByTagName('head')[0].appendChild(s);
	} 	
	checkJQuery();
}

