<!--
function openWin(URL){
    aWindow=window.open(URL,"","width=750,height=550,status=yes,scrollbars=yes,toolbar=no,menubar=no,resizable=yes,top=1,left=1");
}
function openWinP(URL){
    aWindow=window.open(URL,"","width=750,height=550,status=yes,scrollbars=yes,toolbar=no,menubar=yes,resizable=yes,top=1,left=1");
}
function openWinG(URL,width,height){
    aWindow=window.open(URL,"","width="+width+",height="+height+",status=yes,scrollbars=yes,toolbar=no,menubar=yes,resizable=yes,top=1,left=1");
}
function openWinF(URL,width,height){
    aWindow=window.open(URL,"","width="+width+",height="+height+",status=no,scrollbars=no,toolbar=no,menubar=no,resizable=no,top=1,left=1");
}
function MM_openBrWindow(URL) {
    aWindow=window.open(URL,'popup','width=640,height=530,left=0,top=0,status=yes,scrollbars=yes');
}
function MM_openBrWindow2(URL) {
    aWindow=window.open(URL,'popup2','width=160,height=530,left=650,top=0,status=yes,scrollbars=yes');
}
function MM_openBrWindow3(URL) {
    aWindow=window.open(URL,'popup3','width=640,height=400,left=0,top=0,status=yes,scrollbars=yes');
}

function fullReload(pageLink) {
    n = pageLink.indexOf('?');
    pageLink = mainProg+pageLink.substring(n);
    top.location.href = pageLink;
}
function showDaysToGo(daysToGo,option,beforetext,duringtext,aftertext) {
    option = option.toLowerCase();
    outputString='&nbsp;';
    bBeforeEvent = (daysToGo > 0);
    bDuringEvent = (daysToGo < 0);
    bAfterEvent  = (daysToGo == 0);
    if (daysToGo < 0) daysToGo = -daysToGo;
    if (option=='days') {
		if (!bAfterEvent) outputString = ''+daysToGo;
   	} else {
   		if (bBeforeEvent) outputString = beforetext;
   		if (bDuringEvent) outputString = duringtext;
   		if (bAfterEvent) outputString = aftertext;
   	}
    document.write(outputString);
}
function showShortDate(dateStr) {
	dateBits = dateStr.split(' ');
	document.write(dateBits[1]+' '+dateBits[2].toLowerCase()+' '+dateBits[3].substr(2,2));
}
function jumpHome(pageLink,daysToGo) {
    bBeforeEvent = (daysToGo > 0);
    bDuringEvent = (daysToGo < 0);
    bNoDisplay = (daysToGo == 0);
    if (daysToGo < 0) daysToGo = -daysToGo;
    daysString = ''+daysToGo;
    if ((bNoDisplay) || (bBeforeEvent))
    	newSection="home";
    else
        newSection="day"+daysString;
    window.location.href=pageLink+"&section="+newSection;
}

var hLayers = new Array();
function regLayers() {
    if (document.layers) {
        for (i=0;i<document.layers.length; i++) {
            if (document.layers[i].name.indexOf("hidelayer_") != -1)
                hLayers[hLayers.length] = document.layers[i].name;
        }
    } else {
        for (i=0;i<document.all.length; i++) {
            if (document.all[i].id.indexOf("hidelayer_") != -1)
                hLayers[hLayers.length] = document.all[i].id;
        }
    }
}
function hideLayers() {
    for (i=0;i<hLayers.length; i++) {
        if (document.layers)
            document.layers[hLayers[i]].visibility = "hide";
        else
            document.all[hLayers[i]].style.visibility = "hidden";
    }
}
function showLayers() {
    for (i=0;i<hLayers.length; i++) {
        if (document.layers)
            document.layers[hLayers[i]].visibility = "show";
        else
            document.all[hLayers[i]].style.visibility = "visible";
    }
}
//-->
