function caljump() {
	var datefield;
	var dateval;
	
	datefield = document.getElementById("jumpto");
	dateval = datefield.options[datefield.selectedIndex].value;
	document.catform.selcat.value = document.getElementById("category").options[document.getElementById("category").selectedIndex].value;
	//alert('Date Value: ' + dateval);
	if (dateval != '') {
		var datearray = dateval.split('/');
		if (parseInt(datearray[0]) && parseInt(datearray[1])) {
			//alert('Month: ' + datearray[0] + ', Year: ' + datearray[1]);
			//window.location.href = 'calendar.php?m=' + datearray[0] + '&y=' + datearray[1];
			document.catform.m.value = datearray[0];
			document.catform.y.value = datearray[1];
			document.catform.v.value = 'monthly';
			/*
			Check for Athletics
			*/
			document.getElementById("catform").target = "_self";
			document.getElementById("catform").action = "calendar-of-events";
			/*
			End Athletics
			*/
			
			document.catform.submit();
		}
	}	
}

function callistjump() {
	var datefield;
	var dateval;
	
	datefield = document.getElementById("jumpto2");
	dateval = datefield.options[datefield.selectedIndex].value;
	document.catform.selcat.value = document.getElementById("category2").options[document.getElementById("category2").selectedIndex].value;
	//alert('Date Value: ' + dateval);
	if (dateval != '') {
		var datearray = dateval.split('/');
		if (parseInt(datearray[0]) && parseInt(datearray[1])) {
			//alert('Month: ' + datearray[0] + ', Year: ' + datearray[1]);
			//window.location.href = 'calendar.php?v=list&m=' + datearray[0] + '&y=' + datearray[1];
			document.catform.m.value = datearray[0];
			document.catform.y.value = datearray[1];
			document.catform.v.value = 'list';
			document.catform.submit();
		}
	}	
}

function navmonth(thismonth, thisyear) {
	document.catform.m.value = thismonth;
	document.catform.y.value = thisyear;
	document.catform.v.value = 'monthly';
	document.catform.submit();
}
function navmonthlist(thismonth, thisyear) {
	document.catform.m.value = thismonth;
	document.catform.y.value = thisyear;
	document.catform.v.value = 'list';
	document.catform.submit();
}
function showtab(tabname) {
	if (tabname == 'monthly') {
		document.getElementById('cal_icon_monthly').className = "cal_on";
		document.getElementById('cal_icon_list').className = "cal_off";
		document.getElementById('calendar_monthly').style.display = '';
		document.getElementById('calendar_list').style.display = 'none';
		document.catform.v.value = 'monthly';
	} else {
		document.getElementById('cal_icon_monthly').className = "cal_off";
		document.getElementById('cal_icon_list').className = "cal_on";
		document.getElementById('calendar_monthly').style.display = 'none';
		document.getElementById('calendar_list').style.display = '';
		document.catform.v.value = 'list';
	}
}


