function getMsg(ActionID,Argument) {
	//get the URL, what will be used in Ajax
	var url = "./ViewPublic/Msg.php?ActionID="+ActionID+"&Argument="+Argument;
	//initail Ajax
	var ajax = InitAjax();
	var isAsynchronous = false;
	var info;
	//do apply (method:get,address:url,transfer:synchronization)
	ajax.open("GET", url, isAsynchronous);
	//set function
	if(!isAsynchronous && navigator.userAgent.indexOf("Firefox") > 0) {
		//set "Get" data
		ajax.send(null);
		//get return info
		info = ajax.responseText;
	} else {
		//get operation status
		ajax.onreadystatechange = function (strErrorMessage) {
			//if the status is normal, then return the value
			if (ajax.readyState == 4 && ajax.status == 200) {
				//get ajax return value
				info = ajax.responseText;
			}
		}
		//set "Get" data
		ajax.send(null);
	}
	//return info	
	return info;
}

function alertMsg(ActionID,Argument) {
	alert(getMsg(ActionID,Argument));
}

function check_answer() {
	if($('strPwdAnswer1').value == '') {
		alertMsg('10002','PwdAnswer1');
		return false;
	}
	xajax_checkAnswer($('uid').value,'strPwdAnswer1',$('strPwdAnswer1').value);
	return false;
}

function check_password(){
	if($('strPassword').value == '') {
		alertMsg('10002','Password');
		return false;
	}
	if($('strPassword').value.length < 6) {
		alertMsg('10005','');
		return false;
	}
	if($('strPassword').value != $('strPassword2').value) {
		alertMsg('10006');
		return false;
	}
	return true;
}

function check_product_comment() {
	//check strInput validation
	if ($("strCustomerName_2") && $("strCustomerName_2").value == "") 
	{
		//set value of error message
		strMessage = "请输入用户名!";
		//show error message,mention user to input data
		alert(strMessage);
		//focus the column
		$("strCustomerName_2").focus();
		//return false and terminate submit
		return false;
	}
	//check strInput validation
	if ($("txtComment") && $("txtComment").value == "") 
	{
		//set value of error message
		strMessage = "请输入您的评论!";
		//show error message,mention user to input data
		alert(strMessage);
		//focus the column
		$("txtComment").focus();
		//return false and terminate submit
		return false;
	}
	$("InsertProductComment").submit();
}







