JQuery正则表达式判断用户名不能必须为数字,字母下划线或汉字
if (!/^(?!_)(?!.*?_$)[a-zA-Z0-9_u4e00-u9fa5]+$/.test(userName)){ alert(“用户名密码不合法!”);}
不怂!!
if (!/^(?!_)(?!.*?_$)[a-zA-Z0-9_u4e00-u9fa5]+$/.test(userName)){ alert(“用户名密码不合法!”);}
if(!(/^(w-*.*)+@(w-?)+(.w{2,})+$/.test(peopleMail)){ alert(“邮箱格式有误!”)}
if(!(/^1[3|4|5|8][0-9]d{4,8}$/.test(peoplePhone)){ alert(“手机号格式有误!”)}
$(“button[name=”reg”]”).attr(“disabled”, true);
获取浏览器显示区域(可视区域)的高度 :$(window).height(); 获取浏览器显示区域(可视区域)的宽度 :$(window).width(); 获取页面的文档高度 $(document).height(); 获取页面的文档宽度 : $(document).width(); 浏览器当前窗口文档body的高度: $(document.body).height(); 浏览器当
$(“.flag”).delegate(“a”,”click”,function(){ $(“.reply”).hide(); $(“.replyDown”).show(); $(“.replyInput”).slideDown(700).css(“display”,”block”);});$(“.flag”).delegate(“a”,”click”,function(){ $(“.replyD
alert(“####111″+msg); //对象alert(“####222″+msg.result); //结果 true表示查询到了,false不存在alert(“####333″+msg.code); //查询到的编码alert(“####444″+msg.resultData); //查询时间alert(“####555″+msg.resultMsg); //查询