I'm building a Google App Engine app, and I have a class to represent an RSS Feed.
I have a method called setUrl which is part of the feed class. It accepts a url as an input.
I'm trying to use the re python module to validate off of the RFC 3986 Reg-ex (http://www.ietf.org/rfc/rfc3986.txt)
Below is a snipped which should work, right? I'm incredibly new to Python and have been beating my head against this for the past 3 days.
p = re.compile('^(([^:/?#]+):)?(//([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?')
m = p.match(url)
if m:
self.url = url
return url