﻿// JScript File

	function ModalPopUpShow(divBckg, divPopUp){
		divBckg = document.getElementById(divBckg);
		divPopUp = document.getElementById(divPopUp);
		divBckg.style.display='';
		divPopUp.style.display='';
		divBckg.style.zIndex=10000;
		divPopUp.style.zIndex=10001;
	}


	function ModalPopUpHide(divBckg, divPopUp){
		divBckg = document.getElementById(divBckg);
		divPopUp = document.getElementById(divPopUp);
		divBckg.style.display='none';
		divPopUp.style.display='none';
	}

	function isBlank(s){
		for (var i = 0; i < s.length; i++){
			var c = s.charAt(i);
			if ((c != ' ') && (c != '\n') && (c != '\t')) return false;
		}
		return true;
	}		
	
	function IsEmpty(e){
		var bRet = false;
		if (e == "" || e == null || isBlank(e)){
			bRet = true;
		}
		return bRet;
	}		


	function IsMail(x){
		var filter  = /^([a-zA-Z0-9_\.\-])+\@(([a-zA-Z0-9\-])+\.)+([a-zA-Z0-9]{2,4})+$/;
		if (filter.test(x)){
			return true;
		}else{
			return false;
		}
	}


