js验证密码、重复密码
摘要:js验证密码、重复密码是否输入6-20位,是否输入相同。functioncheck(){if(document.getElementById('<%=TxtPwd.ClientID%>').value==''){alert('请填写密码!');document.getElementById('<%=TxtPwd.ClientID%>').focus();returnfalse;}if(document.getElementById('<%=TxtRePwd.ClientID%>'
阅读全文
posted @
2012-07-17 10:55
江南荷韵
阅读(1362)
推荐(0)
js验证用户名
摘要:js验证用户名是否为空、输入长度,暂时没有用ajax异步验证用户名是否存在。functioncheck(){if(document.getElementById('<%=TxtUserName.ClientID%>').value==''){alert('请填写用户名!');document.getElementById('<%=TxtUserName.ClientID%>').focus();returnfalse;}//此处的方法是判断是汉字时字符+1//functionstrlen(str){//va
阅读全文
posted @
2012-07-17 10:51
江南荷韵
阅读(864)
推荐(0)
js去除空格
摘要:转载的哦~~~~ 嘿嘿。。。 str为要去除空格的字符串:去除所有空格:str = str.replace(/\s+/g,"");去除两头空格:str = str.replace(/^\s+|\s+$/g,"");去除左空格:str=str.replace( /^\s*/, '');去除右空格:str=str.replace(/(\s*$)/g, "");SCRIPT LANGUAGE="JavaScript"> <!-- //出处:网上搜集// Trim() , Ltrim() , R
阅读全文
posted @
2012-07-12 17:54
江南荷韵
阅读(203)
推荐(0)
javascript“设为首页”与“加入收藏”兼容多浏览器代码
摘要:代码 Code highlighting produced by Actipro CodeHighlighter (freeware)http://www.CodeHighlighter.com/-->1<htmlxmlns="http://www.w3.org/1999/xhtml">2<headrunat="server">3<title>无标题页</title>4<scriptlanguage="javascript"type="text/javascript
阅读全文
posted @
2010-01-23 14:32
江南荷韵
阅读(797)
推荐(0)