function popUp(URL) {
	day = new Date();
	id = day.getTime();
	eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=1,resizable=1,width=400,height=300');");
}
function popUpGift(URL) {
	day = new Date();
	id = day.getTime();
	eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=1,scrollbars=1,location=1,statusbar=1,menubar=1,resizable=1,width=600,height=450');");
}
function show_element(element) {
	document.getElementById(element).style.display = "block";
}
function hide_element(element) {
	document.getElementById(element).style.display = "none";
}
function over(name){
	window.document.images[name].src =  "/images/" + name + "_on.gif";
}
function out(name){
	window.document.images[name].src =  "/images/" + name + ".gif";
}
/* Preload images */
if (document.images) {
  pic1 = new Image(200,90); 
  pic1.src = "/images/200_sounds_of_eastman_on.gif"; 
}
/* Timer Delay Function for Menus */
function Timer(){
    this.obj = (arguments.length)?arguments[0]:window;
    return this;
}
Timer.prototype.setInterval = function(func, msec){
    var i = Timer.getNew();
    var t = Timer.buildCall(this.obj, i, arguments);
    Timer.set[i].timer = window.setInterval(t,msec);
    return i;
}
Timer.prototype.setTimeout = function(func, msec){
    var i = Timer.getNew();
    Timer.buildCall(this.obj, i, arguments);
    Timer.set[i].timer = window.setTimeout("Timer.callOnce("+i+");",msec);
    return i;
}
Timer.prototype.clearInterval = function(i){
    if(!Timer.set[i]) return;
    window.clearInterval(Timer.set[i].timer);
    Timer.set[i] = null;
}
Timer.prototype.clearTimeout = function(i){
    if(!Timer.set[i]) return;
    window.clearTimeout(Timer.set[i].timer);
    Timer.set[i] = null;
}
Timer.set = new Array();
Timer.buildCall = function(obj, i, args){
    var t = "";
    Timer.set[i] = new Array();
    if(obj != window){
        Timer.set[i].obj = obj;
        t = "Timer.set["+i+"].obj.";
    }
    t += args[0]+"(";
    if(args.length > 2){
        Timer.set[i][0] = args[2];
        t += "Timer.set["+i+"][0]";
        for(var j=1; (j+2)<args.length; j++){
            Timer.set[i][j] = args[j+2];
            t += ", Timer.set["+i+"]["+j+"]";
    }}
    t += ");";
    Timer.set[i].call = t;
    return t;
}
Timer.callOnce = function(i){
    if(!Timer.set[i]) return;
    eval(Timer.set[i].call);
    Timer.set[i] = null;
}
Timer.getNew = function(){
    var i = 0;
    while(Timer.set[i]) i++;
    return i;
}
/* Hover function for dropdown menus */
sfHover = function() {
	var sfEls = document.getElementById("top_menu").getElementsByTagName("LI");
	for (var i=0; i<sfEls.length; i++) {
		sfEls[i].onmouseover=function() {
			this.className+=" sfhover";
		}
		sfEls[i].onmouseout=function() {
			this.timer = new Timer(this);
			this.timer.setTimeout("out",500);
		}
		sfEls[i].out=function() {
			this.className=this.className.replace(new RegExp("\\bsfhover\\b"), "");
		}
	}
}
if (window.addEventListener) window.addEventListener( "load", sfHover, false );
if (window.attachEvent) window.attachEvent("onload", sfHover);