惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

D
Docker
爱范儿
爱范儿
T
The Exploit Database - CXSecurity.com
量子位
T
Tailwind CSS Blog
T
Threatpost
The GitHub Blog
The GitHub Blog
AWS News Blog
AWS News Blog
云风的 BLOG
云风的 BLOG
K
Kaspersky official blog
P
Proofpoint News Feed
博客园 - 司徒正美
L
LangChain Blog
T
Threat Research - Cisco Blogs
C
CERT Recently Published Vulnerability Notes
罗磊的独立博客
酷 壳 – CoolShell
酷 壳 – CoolShell
博客园 - 叶小钗
S
Secure Thoughts
The Last Watchdog
The Last Watchdog
Spread Privacy
Spread Privacy
H
Hacker News: Front Page
T
Troy Hunt's Blog
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
Google DeepMind News
Google DeepMind News
W
WeLiveSecurity
A
Arctic Wolf
Apple Machine Learning Research
Apple Machine Learning Research
cs.AI updates on arXiv.org
cs.AI updates on arXiv.org
P
Proofpoint News Feed
T
Tor Project blog
T
The Blog of Author Tim Ferriss
I
Intezer
P
Privacy & Cybersecurity Law Blog
美团技术团队
N
Netflix TechBlog - Medium
博客园_首页
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
V
Vulnerabilities – Threatpost
Application and Cybersecurity Blog
Application and Cybersecurity Blog
G
Google Developers Blog
Attack and Defense Labs
Attack and Defense Labs
T
Tenable Blog
月光博客
月光博客
Stack Overflow Blog
Stack Overflow Blog
J
Java Code Geeks
腾讯CDC
Microsoft Security Blog
Microsoft Security Blog
A
About on SuperTechFans
Last Week in AI
Last Week in AI

博客园 - 虚空境界

当WEB站点应用程序池标识为ApplicationPoolIdentity,出现运行错误时的解决方法 sql表设计器的几个默认值 easyui中tree型控件不正常显示的处理方法 Ajax.ActionLink与Ajax.BeginForm使用场所的思考 mvc中ajax.beginform一次提交重复Post两次的问题解决 JQuery EasyUI弹出对话框解决Asp.net服务器控件无法执行后台代码的方法(转) 后台动态设置前台标签内容和属性(转自http://www.wzsky.net/html/Program/net/26171.html) ASP.NET中使用 Response.Write("<script>alert('****');</script>");后CSS界面发生变化的解决方法 (经验证) silverlight控件如何自适应 “System.ServiceModel.DomainServices.Client.DomainOperationException:查询"XXX"load操作失败,远程服务器返回了错误:NoFound.……”解决方法 按规定长度显示指定绑定字段的内容 asp.net中使用ckfinder2选择图片并返回图片文件的路径的代码 CKEditor3.6.1+CKFinder2.0.2结合 打造"帅"的编辑器 For .Net WEB.CONFIG资料收集 ckeeditor和ckfinder在asp.net中的使用 用户体验的网站首页设计的准则 开发播放器中所学/用到的知识 关于使用IDE制作样式表后不能正常显示的问题 域用户组策略禁用QQ等软件 域用户组策略设定IE主页
ASP.NET验证控件RegularExpressionValidator的常见表达式
虚空境界 · 2013-12-23 · via 博客园 - 虚空境界

可以输入非0和0开头的数字:“^(0*[1-9][0-9]*|[1-9][0-9]*)$”
只能输入数字:“^[0-9]*$”
只能输入n位的数字:“^\d{n}$”
只能输入至少n位数字:“^\d{n,}$”
只能输入m-n位的数字:“^\d{m,n}$”
只能输入零和非零开头的数字:“^(0|[1-9][0-9]*)$”
只能输入有两位小数的正实数:“^[0-9]+(.[0-9]{2})?$”
只能输入有1-3位小数的正实数:“^[0-9]+(.[0-9]{1,3})?$”
只能输入非零的正整数:“^\+?[1-9][0-9]*$”
只能输入非零的负整数:“^\-[1-9][0-9]*$”
只能输入长度为3的字符:“^.{3}$”
只能输入由26个英文字母组成的字符串:“^[A-Za-z]+$”
只能输入由26个大写英文字母组成的字符串:“^[A-Z]+$”
只能输入由26个小写英文字母组成的字符串:“^[a-z]+$”
只能输入由数字和26个英文字母组成的字符串:“^[A-Za-z0-9]+$”
只能输入由数字、26个英文字母或者下划线组成的字符串:“^\w+$”
验证用户密码:“^[a-zA-Z]\w{5,17}$”正确格式为:以字母开头,长度在6-18之间,只能包含字符、数字和下划线。
验证是否含有^%&',;=?$\"等字符:“[^%&',;=?$\x22]+”
只能输入汉字:“^[\u4e00-\u9fa5],{0,}$”
验证Email地址:“^\w+[-+.]\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*$”
验证InternetURL:“^http://([\w-]+\.)+[\w-]+(/[\w-./?%&=]*)?$”
验证电话号码:“^(\(\d{3,4}\)|”,“XXXX-XXXXXXXX”,“XXX-XXXXXXX”,
“XXX-XXXXXXXX”,“XXXXXXX”,“XXXXXXXX”。
验证身份证号(15位或18位数字):“^\d{15}|\d{}18$”
验证一年的12个月:“^(0?[1-9]|1[0-2])$”正确格式为:“01”-“09”和“1”“12”
验证一个月的31天:“^((0?[1-9])|((1|2)[0-9])|30|31)$”
正确格式为:“01”“09”和“1”“31”。
^[\u4e00-\u9fa5\w]+$ //由汉字、数字、26个英文字母或者下划线组成的字符串
"^\d+$" //非负整数(正整数   +   0)    
"^[0-9]*[1-9][0-9]*$"  //正整数    
"^((-\d+)|(0+))$"  //非正整数(负整数   +   0)    
"^-[0-9]*[1-9][0-9]*$"  //负整数    
"^-?\d+$"    //整数    
"^\d+(\.\d+)?$"  //非负浮点数(正浮点数   +   0)    
"^(([0-9]+\.[0-9]*[1-9][0-9]*)|([0-9]*[1-9][0-9]*\.[0-9]+)|([0-9]*[1-9][0-9]*))$"  //正浮点数    
"^((-\d+(\.\d+)?)|(0+(\.0+)?))$"  //非正浮点数(负浮点数   +   0)    
"^(-(([0-9]+\.[0-9]*[1-9][0-9]*)|([0-9]*[1-9][0-9]*\.[0-9]+)|([0-9]*[1-9][0-9]*)))$"  //负浮点数    
"^(-?\d+)(\.\d+)?$"  //浮点数    
"^[A-Za-z]+$"  //由26个英文字母组成的字符串    
"^[A-Z]+$"  //由26个英文字母的大写组成的字符串    
"^[a-z]+$"  //由26个英文字母的小写组成的字符串    
"^[A-Za-z0-9]+$"  //由数字和26个英文字母组成的字符串    
"^\w+$"  //由数字、26个英文字母或者下划线组成的字符串    
"^[\w-]+(\.[\w-]+)*@[\w-]+(\.[\w-]+)+$"    //email地址    
"^[a-zA-z]+://(\w+(-\w+)*)(\.(\w+(-\w+)*))*(\?\S*)?$"  //url 
日期:^((((1[6-9]|[2-9]\d)\d{2})-(0?[13578]|1[02])-(0?[1-9]|[12]\d|3[01]))| (((1[6-9]|[2-9]\d)\d{2})-(0?[13456789]|1[012])-(0?[1-9]|[12]\d|30))|(((1[6-9]|[2-9]\d)\d{2})-0?2-(0?[1-9]|1\d|2[0-8]))|(((1[6-9]|[2-9]\d)(0[48]|[2468][048]|[13579][26])|((16|[2468][048]|[3579][26])00))-0?2-29-))$