[javascript]代码库
//用户名验证
function checkName(name, url, oper, show_id) {
//alert(1);
if(!checkCustName(name,show_id)) {
return false;
}
Ext.Ajax.request({
url : url,
params : {
oper : oper,
name : name
},
success : function(response) {
var res = response.responseText;
var ress=res.replace(/[^\u4E00-\u9FA5]/g,'');
alert(ress);
//var reg = /color\=\"green\"/;
//hideBgImg(show_id, reg.test(res));
//Ext.get(show_id).update(response.responseText);
return true;
},
failure : function(response) {
return false;
}
});
}
//var ress=res.replace(/[^\u4E00-\u9FA5]/g,'');