// JavaScript Document
<!--
function ShowHide(id, visibility) {
    obj = document.getElementsByTagName("div");
    obj[id].style.visibility = visibility;
}

function Change1()
{
if (document.form1.Other_User.checked == true) 
  	{ 
  		document.form1.Other_User_Name.disabled = false;		
  	}
else
  	{ 
  		document.form1.Other_User_Name.disabled = true; 
	}
}

function DayEnabler()
{
if (document.form1.RecurYes.checked == true)
	{
			document.form1.Mon.disabled =false;
			document.form1.Tue.disabled =false;
			document.form1.Wed.disabled =false;
			document.form1.Thu.disabled =false;
			document.form1.Fri.disabled =false;
			document.form1.Sat.disabled =false;
			document.form1.Sun.disabled =false;																								
	}
else
	{	
			document.form1.Mon.disabled =true;
			document.form1.Tue.disabled =true;
			document.form1.Wed.disabled =true;
			document.form1.Thu.disabled =true;
			document.form1.Fri.disabled =true;
			document.form1.Sat.disabled =true;
			document.form1.Sun.disabled =true;
			document.form1.Mon.checked =false;
			document.form1.Tue.checked =false;
			document.form1.Wed.checked =false;
			document.form1.Thu.checked =false;
			document.form1.Fri.checked =false;
			document.form1.Sat.checked =false;
			document.form1.Sun.checked =false;
	}
}

function ClearDisabled1()
{
	document.form1.Other_User_Name.disabled = true;
	document.form1.EventNam.disabled = true;
	document.form1.CourseNum.disabled = false;
	document.form1.Projector_List.disabled = true;
	document.form1.Tape_List.disabled = true;
	document.form1.Mon.disabled =true;
	document.form1.Tue.disabled =true;
	document.form1.Wed.disabled =true;
	document.form1.Thu.disabled =true;
	document.form1.Fri.disabled =true;
	document.form1.Sat.disabled =true;
	document.form1.Sun.disabled =true;
}

function Change2()
{
if (document.form4.Other_User.checked == true) 
  	{ 
  		document.form4.Other_User_Name.disabled = false;		
  	}
else
  	{ 
  		document.form4.Other_User_Name.disabled = true; 
	}
}

function ClearDisabled2()
{
	document.form4.Other_User_Name.disabled = true;
	document.form4.EventNam.disabled = true;
}

function Enabler1()
{
if (document.form1.Course.checked == true) 
  	{ 
  		document.form1.CourseNum.disabled = false;
		document.form1.EventNam.disabled = true;
  	}
else if (document.form1.Event.checked == true)
  	{ 
  		document.form1.CourseNum.disabled = true;
		document.form1.EventNam.disabled = false;
	}
}

function Enabler2()
{
if (document.form4.Course.checked == true) 
  	{ 
  		document.form4.CourseNum.disabled = false;
		document.form4.EventNam.disabled = true;
  	}
else if (document.form4.Event.checked == true)
  	{ 
  		document.form4.CourseNum.disabled = true;
		document.form4.EventNam.disabled = false;
	}
}

function Change_Projector()
{
if (document.form1.Projector.checked == false) 
  { document.form1.Projector_Q.disabled = true; }
else
  { document.form1.Projector_Q.disabled = false; }
}

function Change_Tape()
{
if (document.form1.Tape.checked == false) 
  { document.form1.Tape_Q.disabled = true; }
else
  { document.form1.Tape_Q.disabled = false; }
}

function y2k(number)    { return (number < 1000) ? number + 1900 : number; }

var today = new Date();
var day   = today.getDate();
var month = today.getMonth();
var year  = y2k(today.getYear());

function padout(number) { return (number < 10) ? '0' + number : number; }

//For AV Reservation
function restart() {
    document.form1.Sdate.value = '' + padout(month - 0 + 1) + '/' + padout(day) + '/' + year;
    mywindow.close();
}

//For AV Reservation
function restart2() {
    document.form1.Edate.value = '' + padout(month - 0 + 1) + '/' + padout(day) + '/' + year;
    mywindow.close();
}

//For Project Request
function restart3() {
    document.form4.Sdate.value = '' + padout(month - 0 + 1) + '/' + padout(day) + '/' + year;
    mywindow.close();
}

//For Installment Request
function restart4() { 
    document.form5.NDate.value = '' + padout(month - 0 + 1) + '/' + padout(day) + '/' + year;
    mywindow.close();
}

//For Trouble Report
function restart5() {
    document.form2.DateTR.value = '' + padout(month - 0 + 1) + '/' + padout(day) + '/' + year;
    mywindow.close();
}

function newWindow() {
    mywindow=open('cal.htm','myname','resizable=no,width=350,height=300');
    mywindow.location.href = 'cal.htm';
    if (mywindow.opener == null) mywindow.opener = self;
}

function newWindow2() {
    mywindow=open('cal2.htm','myname','resizable=no,width=350,height=300');
    mywindow.location.href = 'cal2.htm';
    if (mywindow.opener == null) mywindow.opener = self;
}

function newWindow3() {
    mywindow=open('cal3.htm','myname','resizable=no,width=350,height=300');
    mywindow.location.href = 'cal3.htm';
    if (mywindow.opener == null) mywindow.opener = self;
}

function newWindow4() {
    mywindow=open('cal4.htm','myname','resizable=no,width=350,height=300');
    mywindow.location.href = 'cal4.htm';
    if (mywindow.opener == null) mywindow.opener = self;
}

function newWindow5() {
    mywindow=open('cal5.htm','myname','resizable=no,width=350,height=300');
    mywindow.location.href = 'cal5.htm';
    if (mywindow.opener == null) mywindow.opener = self;
}

//-->