文章分类 -  正则表达式

摘要:原文:http://blog.sunmast.com/Sunmast/archive/2004/07/30/799.aspx 这里是几个主要非英文语系字符范围(google上找到的): 2E80~33FFh:中日韩符号区。收容康熙字典部首、中日韩辅助部首、注音符号、日本假名、韩文音符,中日韩的符号、标点、带圈或带括符文数字、月份,以及日本的假名组合、单位、年号、月份、日期、时间等。 3400~4... 阅读全文
posted @ 2005-05-11 11:14 dudu 阅读(10593) 评论(5) 推荐(0) 编辑
摘要:应用也很简单,以上函数均是应用在服务器端,若用在客户端需要把runat=server去掉。我举两个例子: IF isIPaddress.test(str)=false THEN Response.Write"IP 地址错误,请重新输入。" Response.End END IF IF TestPwd(str)=false THEN Respon... 阅读全文
posted @ 2005-04-11 14:53 dudu 阅读(4825) 评论(1) 推荐(0) 编辑
摘要:一、验证类 1、数字验证内 1.1 整数 /^(-│+)?d+$/ 不可以为空 /^[-+]?d*$/ 可以为空 1.2 大于0的整数 (用于传来的ID的验证) /^d+$/ 1.3 负整数的验证 /^-d+$/ 1.4 整数不能大于iMax 根据上面的正则可以写出。 1.5 整数不能小于iMin 根据上面的正则可以写出。 2、时间类 2.1 短时间,形如 (13:04:06) func... 阅读全文
posted @ 2005-04-11 14:50 dudu 阅读(5622) 评论(0) 推荐(0) 编辑
摘要:bluesean 正则表达式(一) 一、简介 正则表达式这个名词,相信很多人都听说过,这个名词最早起源于1956 年, 一位叫 Stephen Kleene 的美国数学家在 McCulloch 和 Pitts 早期工作的基础上,发表了一篇标题为“神经网事件的表示法”的论文,引入了正则表达式的概念。正则表达式就是用来描述他称为“正则集的代数”的表达式,因此采用“正则表... 阅读全文
posted @ 2004-07-25 14:04 dudu 阅读(11064) 评论(4) 推荐(0) 编辑
摘要:Solution Title: Regular Expressions to remove or replaceAuthor: pmengalPoints: 500 Grade: ADate: 05/12/2003 01:18AM PDT Hello,I want to use a regular expression to replace or remove some texts... 阅读全文
posted @ 2004-03-09 09:32 dudu 阅读(3281) 评论(1) 推荐(0) 编辑
摘要:/* * This is a conversion of some of the regular expressions listed in * the Perl CookBook. * compile this sample with the command line: * csc /debug /r:System.Text.RegularExpressions.dll cookbook.cs ... 阅读全文
posted @ 2004-02-23 15:15 dudu 阅读(1736) 评论(0) 推荐(0) 编辑