String.prototype.byteLength=function(){return this.replace(/[^\u0000-\u007f]/g,"\u0061\u0061").length;};
function checkFormat(s){
}
function G(id){return document.getElementById(id);}
function isYes(){
var one=G("newPassword").value;
var two=G("newPassword2").value;
if(one!=two){
G("password_error").innerHTML="密码与确认密码不一致";
return;
}else if(one==""){
G("password_error").innerHTML="请填写密码";
return;
}else if(one.byteLength() > 14 || one.byteLength() < 6){
G("password_error").innerHTML="密码应由6至14个字符组成";
return;
}else if(one != '' && !one.match(/^[\x21-\x7e]{1,14}$/ig)){
G("password_error").innerHTML="密码仅可由数字,字母和下划线组成";
return;
}
G("passwordBox_form").submit();
}