//***********************************************
//		Menu javascript
//***********************************************

function ShowComboBoxes(blnShow) {

	for (i=0;i<document.all.tags("select").length;i++) {
		var objElem=document.all.tags("select")[i]
		if (blnShow==true)
			objElem.style.visibility="visible"
		else
			objElem.style.visibility="hidden"
	}
}
 

function f_date(){
	var now = new Date();
	var intDate = now.getDate();
	var intWeekDay = now.getDay();
	var intMonth = now.getMonth();
	var intYear = now.getYear();
	var strWeekDayNames = new Array(__weekdays__);
	var strMonthNames = new Array(__months__);
	var strDaylectico = "" ;
			
	if (intYear < 1000) intYear +=1900;
	strDaylectico= intDate + " " + strMonthNames[intMonth] + " " + intYear;
	document.write(strDaylectico)
}
startList = function() {
	
	if (document.all&&document.getElementById) {
		cssdropdownRoot = document.getElementById("cssdropdown");
		for (i=0; i<cssdropdownRoot.childNodes.length; i++) {
			node = cssdropdownRoot.childNodes[i];
			if (node.nodeName=="LI") {
				node.onmouseover=function() {
				this.className+=" over";
				ShowComboBoxes(false);
				}
				node.onmouseout=function() {
					this.className=this.className.replace(" over", "");
					ShowComboBoxes(true);
				}
			}
		}
	}
}

if (window.attachEvent)
window.attachEvent("onload", startList)
else
window.onload=startList;
//validate function for login 
function frm_Validate(){
	var blnreturn = true
	if (document.frm_validate.txtusrname.value == ""){
		alert("__lecterrusername__")
		document.frm_validate.txtusrname.focus();
		return false;	
		}
	if (document.frm_validate.txtPassword.value == ""){
		alert("__lecterruserpsw__")
		document.frm_validate.txtPassword.focus();	
		return false;
		}
		
		return true;
}
//middle function for the enter key
	function frm_DoSubmit(){
		if (frm_Validate())
			document.frm_validate.submit();
	}
