Python-Markdown / markdown

A Python implementation of John Gruber’s Markdown with Extension support.
https://python-markdown.github.io/
BSD 3-Clause "New" or "Revised" License
3.74k stars 858 forks source link

Wikilink extension doesn't recognise links with ampersands in them #1268

Closed tw0shoes closed 2 years ago

tw0shoes commented 2 years ago

If we could change this line: WIKILINKRE = r'[[([\w0-9 -]+)]]'

to WIKILINKRE = r'[[([\w0-9 -&]+)]]'

that would fix the issue.

Thanks for everything.

waylan commented 2 years ago

As previously stated:

If I make any changes to this extension is would be to remove it from being included with Markdown. It only remains as it is very old. I suspect a better approach for you would be to either fork it or create your own new extension which offers the behavior you desire.

In fact, you may find a third-party extension which already offers a solution.

tw0shoes commented 2 years ago

Sorry, I did look for it, just didn't see that. Thanks! Sorry for the time-waster.