【发布时间】:2015-12-23 16:57:31
【问题描述】:
我无法让正则表达式工作
[Required]
[Display(Name = "Challonge URL")]
[RegularExpression(@"http://challonge.com/[a-zA-Z0-9]{1-20}", ErrorMessage = "Invalid challonge URL")]
public string Challonge_URL { get; set; }
输入http://challonge.com/56h9ezkf应该是无效的,是不是正则表达式有问题?
【问题讨论】:
-
你是如何使用这个的?使用客户端验证?
标签: c# asp.net regex asp.net-mvc