hey-red / Markdown

Open source C# implementation of Markdown processor, as featured on Stack Overflow.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Auto-URLs are breaking with any url that has an underscore

GoogleCodeExporter opened this issue · comments

What steps will reproduce the problem?
1. Enable auto-url parsing
2. Use this: http://www.youtube.com/watch?v=wsdy_rct6uo
3. Watch DoItalicsAndBold replace the underscores with <em> tags

What is the expected output? What do you see instead?
Expected:  "<a 
href=\"http://www.youtube.com/watch?v=wsdy_rct6uo\">http://www.youtube.com/watch
?v=wsdy_rct6uo</a>"

What I see: 

"<a 
href=\"http://www.youtube.com/watch?v=wsdy<em>rct6uo\">http://www.youtube.com/wa
tch?v=wsdy</em>rct6uo</a>"

What version of the product are you using? On what operating system?


Please provide any additional information below.


Original issue reported on code.google.com by flatout2...@gmail.com on 28 Jan 2014 at 3:27

Currently testing a solution - Moving DoItalicsAndBold above DoAnchors and 
DoAutoLinks

Original comment by flatout2...@gmail.com on 28 Jan 2014 at 3:36

commented

StrictBoldItalic = true
It helped me.