[Tutor] RE Silliness

Omer Jaggojaggo+Py at gmail.com
Sun Jan 4 19:07:31 CET 2009

I'm sorry, burrowed into the reference until my eyes bled.

What I want is to have a regular expression with an optional ending of

(For those interested,
urlMask = r"http://[\w\Q./\?=\R]+"
is ther version w/o the optional <br> ending.)

I can't seem to make a string optional- only a single character via []s. I
for some reason thuoght it'll be ()s, but no help there- it just returns
only the <br>. Anybody?

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/tutor/attachments/20090104/31cf6926/attachment-0001.htm>

More information about the Tutor mailing list