function checkifEnter(e)
{
var key;
key = e.keyCode; //firefox & IE
if (key == 13){
if (false == hotelSearchCheckForm()){
return false;
}
else{
return true;
}
}
else {
return true;
}
}
function hotelSearchCheckForm(){
var sHotelname = $F($('hotelname'));
var sPx = $F($('px'));
var errMsg = "";
if(sHotelname.length < 4){
errMsg = "\nPlease enter at least 4 characters in the hotel name field.";
}
if(errMsg != ""){
alert(errMsg);
return false;
}
else {
$('submit1').onclick = "";
$('submit1').disabled = true;
document.searchform.action = document.searchform.action + '&hotelname=' + sHotelname;
document.searchform.action = document.searchform.action + '&px=' + sPx;
document.searchform.submit();
return true;
}
}
function LoadPage(px){
var sHotelname = $F($('hotelname'));
$('px').value = px;
document.searchform.action = document.searchform.action + '&hotelname=' + sHotelname
document.searchform.action = document.searchform.action + '&px=' + px;
document.searchform.submit();
}
function LoadPage2(px){
var sHotelname = $F($('hotelname'));
$('px').value = px;
document.hotelspagingform.action = document.hotelspagingform.action + '&hotelname=' + sHotelname
document.hotelspagingform.action = document.hotelspagingform.action + '&px=' + px;
document.hotelspagingform.submit();
}
