function fromDate()
{
	today = new Date();

	d = today.getDate();
	m = today.getMonth();
	y = today.getFullYear();

	document.SelForm.ddd.selectedIndex = d+0;
	document.SelForm.ddm.selectedIndex = m+0;
	document.SelForm.ddy.selectedIndex = y-2005;

}

function toDate()
{
	fromDate();

	today = new Date();

	d = today.getDate();
	m = today.getMonth();
	y = today.getFullYear();

	document.SelForm.rdd.selectedIndex = d+5;
	document.SelForm.rdm.selectedIndex = m+0;
	document.SelForm.rdy.selectedIndex = y-2005;
}

function popUp(px,agent,tmp,ac,tc,ap,ddd,ddm,ddy,dth,dtm,rdd,rdm,rdy,rth,rtm)
{
	var px = px.value;
	var agent = agent.value;
	var tmp = tmp.value;
	var ac = ac.value;
	var tc = tc.value;
	var ap = ap.options[ap.selectedIndex].value;
	var ddd = ddd.options[ddd.selectedIndex].value;
	var ddm = ddm.options[ddm.selectedIndex].value;
	var ddy = ddy.options[ddy.selectedIndex].value;
	var dth = dth.options[dth.selectedIndex].value;
	var dtm = dtm.options[dtm.selectedIndex].value;
	var rdd = rdd.options[rdd.selectedIndex].value;
	var rdm = rdm.options[rdm.selectedIndex].value;
	var rdy = rdy.options[rdy.selectedIndex].value;
	var rth = rth.options[rth.selectedIndex].value;
	var rtm = rtm.options[rtm.selectedIndex].value;
	
	var urlString = "./search/page.asp?px=" + px + "&agent=" + agent + "&tmp=" + tmp + "&ac=" + ac +"&tc=" + tc +"&ap=" + ap + "&ddd=" + ddd + "&ddm=" + ddm + "&ddy=" + ddy + "&dth=" + dth + "&dtm=" + dtm + "&rdd=" + rdd + "&rdm=" + rdm + "&rdy=" + rdy + "&rth=" + rth + "&rtm=" + rtm ;
	
	posx = (screen.width/2) - (790/2)
	posy = (screen.height/2) - (540/2)
	if(posx < 0) { posx = 0; }
	if(posy < 0) { posy = 0; }
	
	openWindow(urlString,'_self','width=790,height=540,scrollbars=yes,status=yes,toolbar=yes,resizable=yes,location=no,left='+posx+',top='+posy);

}

function popUpSub(px,agent,tmp,ac,tc,ap,ddd,ddm,ddy,dth,dtm,rdd,rdm,rdy,rth,rtm)
{
	var px = px.value;
	var agent = agent.value;
	var tmp = tmp.value;
	var ac = ac.value;
	var tc = tc.value;
	var ap = ap.options[ap.selectedIndex].value;
	var ddd = ddd.options[ddd.selectedIndex].value;
	var ddm = ddm.options[ddm.selectedIndex].value;
	var ddy = ddy.options[ddy.selectedIndex].value;
	var dth = dth.options[dth.selectedIndex].value;
	var dtm = dtm.options[dtm.selectedIndex].value;
	var rdd = rdd.options[rdd.selectedIndex].value;
	var rdm = rdm.options[rdm.selectedIndex].value;
	var rdy = rdy.options[rdy.selectedIndex].value;
	var rth = rth.options[rth.selectedIndex].value;
	var rtm = rtm.options[rtm.selectedIndex].value;
	
	var urlString = "page.asp?px=" + px + "&agent=" + agent + "&tmp=" + tmp + "&ac=" + ac +"&tc=" + tc +"&ap=" + ap + "&ddd=" + ddd + "&ddm=" + ddm + "&ddy=" + ddy + "&dth=" + dth + "&dtm=" + dtm + "&rdd=" + rdd + "&rdm=" + rdm + "&rdy=" + rdy + "&rth=" + rth + "&rtm=" + rtm ;
	
	posx = (screen.width/2) - (790/2)
	posy = (screen.height/2) - (540/2)
	if(posx < 0) { posx = 0; }
	if(posy < 0) { posy = 0; }
	
	openWindow(urlString,'_self','width=790,height=540,scrollbars=yes,status=yes,toolbar=yes,resizable=yes,location=no,left='+posx+',top='+posy);

}

function openWindow(theURL,winName,features) {
	parkingDisplay = window.open(theURL,winName,features);
	parkingDisplay.focus();
}


function openMoreInfoWindow(urlString,winName,width,height) 
{
	posx = (screen.width/2) - (width/2)
	posy = (screen.height/2) - (height/2)
	if(posx < 0) { posx = 0; }
	if(posy < 0) { posy = 0; }
	FAQWindow=window.open(urlString,winName,'width='+width+',height='+height+',scrollbars=yes,status=no,toolbar=no,resizable=no,left='+posx+',top='+posy);
	FAQWindow.focus();
}
