function trim_all(strObjName){ 
	//this function removes the spaces from the variables
        var strObj = strObjName;
        var strRet = "";
        for (i = 0;i < strObj.length;i++)
        {
                if(strObj.charAt(i) != " " && strObj.charAt(i) != "")
                        strRet = strRet+strObj.charAt(i);
        }
        return strRet;
}

function checkme_hotel(){

	var location = document.hotels.location;
	
	if(trim_all(location.value) == ""){
		document.getElementById('locationalert').style.display='block';
		location.focus();
		return false;
	}else{
		document.getElementById('locationalert').style.display='none';
	}		
	return true;
	
	document.hotels.updte_hotel.value = 1;
		
}
function checkme_event(){

	var event_location = document.events.event_location;
	
	if(trim_all(event_location.value) == ""){
		document.getElementById('event_locationalert').style.display='block';
		event_location.focus();
		return false;
	}else{
		document.getElementById('event_locationalert').style.display='none';
	}		
	return true;
	
	document.events.updte_event.value = 1;
		
}

