FLLogin = new function(){
    this.Submit = function(){
    
        if (f.GetValue('FLpassword')=='' || f.GetValue('FLEmail')==''){
            alert('please enter your email and password');
            return;
        }
    
        var frmFL = document.getElementById('frmFL');
        document.frmFL.Email.value = f.GetValue('FLEmail');
        document.frmFL.Password.value = f.GetValue('FLpassword');
        document.frmFL.submit();
    }
}


function ButtonPostBack(oButton) {      
    oButton.disabled=true;
    Postback(oButton.id,'');
}

function Postback(sCommand, sArgument, bCheckDelete) {

	//confirm delete if required	
	if (bCheckDelete==true) {
		if (confirm('Are you sure that you want to delete this record?')==false) {
			return;
		}
	}
	
//	if (typeof(oWYSIWYG)!='undefined') {
//		TidyXHTML();
//	}
	
	document.forms[0].Command.value=sCommand;
	document.forms[0].Argument.value=sArgument;
	document.forms[0].submit();
}


function ClearSelection(oList) {
	document.getElementById('hid'+oList.name).value='';
}

function DropDownSelect(oList, oEvent, sAutoPostBack) {
				
	var oStoreKeyPress=document.getElementById('hid'+oList.name);
	
	if ((oEvent.keyCode==13)&&(sAutoPostBack!='true')) {
		return;
	} else if ((oEvent.keyCode==13)&&(sAutoPostBack=='true')) {
		Postback(oList.name,'')
	} else if (oEvent.keyCode!=27) {
		oStoreKeyPress.value=oStoreKeyPress.value+String.fromCharCode(oEvent.keyCode);
	} else {
		oStoreKeyPress.value='';
	}
	
	//find it
	SelectItemFromSearch(oList, oStoreKeyPress.value);
	return false;

}