Roll20 uses cookies to improve your experience on our site. Cookies enable you to enjoy certain features, social sharing functionality, and tailor message and display ads to your interests on our site and others. They also help us understand how our site is being used. By continuing to use our site, you consent to our use of cookies. Update your cookie preferences .
×

Link to url with the character ')' in the url

1592186861

Edited 1592186976
How to add an url that contains a ')', it looks like the matching for the url is lazy and stops after the first closing parenthesis. For instance :&nbsp;[NG]( <a href="https://en.wikipedia.org/wiki/Alignment_(Dungeons_%26_Dragons)#Neutral_good" rel="nofollow">https://en.wikipedia.org/wiki/Alignment_(Dungeons_%26_Dragons)#Neutral_good</a> ) returns 'NG#Neutral_good)' with NG being a link to ' <a href="https://en.wikipedia.org/wiki/Alignment_(Dungeons_%26_Dragons" rel="nofollow">https://en.wikipedia.org/wiki/Alignment_(Dungeons_%26_Dragons</a> '. The part ' )#Neutral_good ' of the url is missing in the link and added as a regular text.
1592187586
The Aaron
Roll20 Production Team
API Scripter
I wouldn't call that lazy so much as unexpected. Even knowing a url could contain parenthesis, I can't think of how I'd write a parser to account for it. This best you could hope for is to try encoding it: [NG]( <a href="https://en.wikipedia.org/wiki/Alignment_(Dungeons_%26_Dragons%29#Neutral_good" rel="nofollow">https://en.wikipedia.org/wiki/Alignment_(Dungeons_%26_Dragons%29#Neutral_good</a> )&nbsp;
1592189308

Edited 1592189618
Thanks, the encoding indeed works well for the wikipedia link but I have an other link where it is not working, I don't really see why...&nbsp; [Spell Scroll]( X XX(YYY)ZZZ)&nbsp;&nbsp; [Spell Scroll]( X XX %26 YYY %29 ZZZ) 1. clearly not works due to the ouput being 'ZZZ)'&nbsp; 2. the output is fine with 'Spell Scroll' and the link is as expected but the link looks redirected&nbsp; PD : The lazy word may not be well choosen, I was referring to a lazy matching when your matching engine stops at the first occurrence found (compared to a greedy one).
1592189523

Edited 1592197713
The Aaron
Roll20 Production Team
API Scripter
I'd suggest trying the encoded links directly in the browser, or creating shortened URLs to use instead via something like tinyurl.&nbsp;
Ok, I like the tiny url idea. Not totally automatisable but I will see at the usage. thx