#15014: URLField validator regex does not allow valid domain name ------------------------------------------+--------------------------------- Reporter: posta07 | Owner: nobody Status: new | Milestone: Component: Database layer (models, ORM) | Version: 1.2 Keywords: | Stage: Unreviewed Has_patch: 0 | ------------------------------------------+--------------------------------- For internal urls that I would like to enter into an URLField, I found that the regex that the validator uses flags the url as incorrect even though it is a valid URL.
For exmaple, http://servername/context/context/etc/ is flagged as incorrect. After reviewing the regex that's being used, it appears it's expecting a .com or .biz or some kind of extension. Here is the regex related to testing for the 'domain': (?:[A-Z0-9](?:[A-Z0-9-]{0,61}[A-Z0-9])?\.)+[A-Z]{2,6}\.? As you can see, it expects a period character in the domain name followed by a 2-6 character length extension. -- Ticket URL: <http://code.djangoproject.com/ticket/15014> Django <http://code.djangoproject.com/> The Web framework for perfectionists with deadlines. -- You received this message because you are subscribed to the Google Groups "Django updates" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/django-updates?hl=en.
