﻿/*
	Common Scripts
	-----------------------
*/

/* Key Press */
function keypressmanager(objEvent, func) {

    var iKeyCode, strKey;

    if (isIE) {
        iKeyCode = objEvent.keyCode;
    }
    else {
        iKeyCode = objEvent.which; 
    }

    if (iKeyCode == 13) {
        eval(func);
        return false;
    }
    
    return true;
}

/* Perform property search */
function searchproperties() {
    window.location.href = "/property-list.aspx?location=" + document.getElementById("ddlLocation").value + "&minprice=" + document.getElementById("ddlMinPrice").value + "&maxprice=" + document.getElementById("ddlMaxPrice").value + "&minbeds=" + document.getElementById("ddlMinBeds").value + "&order=" + document.getElementById("ddlOrder").value;
    return false;
}

