Forum: Redcloth Better supporting parenthesis in links...

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
Ryan Alyea (Guest)
on 2009-01-05 08:17
(Received via mailing list)
Attachment: links_containing_parenthesis.patch (0 Bytes)
Is there a better way to support parenthesis in links like Wikipedia
links? Requiring brackets around the link is confusing to many new
users who don't understand why their Wikipedia links won't work. I
wrote a patch on the latest version of RedCloth to support this a lot
better. Instead of stopping on a end parenthesis, it instead looks at
the URL itself. If the number of opening and closing parenthesis are
equal, it allows the end parenthesis in the link. I'm sure there's a
better way, like checking if they are properly nested.

Included is two patches, one for the C code, another to include more
tests. I do not have Java, so I cannot test myself, however it should
be trivial to port.
Jason G. (Guest)
on 2009-01-21 00:19
(Received via mailing list)
Fantastic!  Thank you, Ryan.  I've added it to an existing ticket and
I can't wait to apply your patch.

The ticket's URL is
http://jgarber.lighthouseapp.com/projects/13054-re...

Jason
This topic is locked and can not be replied to.