Kaydet (Commit) e15567bf authored tarafından Adrian Holovaty's avatar Adrian Holovaty

Fixed #1070 -- Improved date validation to limit it to dates 1900 and up.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@2134 bcc190cf-cafb-0310-a4f2-bffc1f526a37
üst 1dc65cb6
......@@ -10,7 +10,7 @@ form field is required.
import re
_datere = r'\d{4}-((?:0?[1-9])|(?:1[0-2]))-((?:0?[1-9])|(?:[12][0-9])|(?:3[0-1]))'
_datere = r'(19|2\d)\d{2}-((?:0?[1-9])|(?:1[0-2]))-((?:0?[1-9])|(?:[12][0-9])|(?:3[0-1]))'
_timere = r'(?:[01]?[0-9]|2[0-3]):[0-5][0-9](?::[0-5][0-9])?'
alnum_re = re.compile(r'^\w+$')
alnumurl_re = re.compile(r'^[\w/]+$')
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment