/* General Functions */

/**
 *
 */
function IsNumeric(e){
    var unicode=e.charCode? e.charCode : e.keyCode
    if (unicode!=8){//if the key isn't the backspace key (which we should allow)
        if (unicode<48||unicode>57){//if not a number
            return false;//disable key press
        }
    }
}

/**
 *
 */
function IsNotEmptyText(objField){
    var strTrim = objField.value.replace(/\s+/g, "");
    if (strTrim.length > 0){
        return true;//field is filled out
    }
    else{
        return false;//field is empty
    }
}

/* Validate for each modules */
function ValidateItemNumber(objField){
    if(!IsNotEmptyText(objField)){
        alert("You have to input the number of items which you want to order.");
        return false;
    }
    return true;
}
