A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://github.com/Python-Markdown/markdown/issues/660 below:

Footnote ref number in TOC · Issue #660 · Python-Markdown/markdown · GitHub

In [13]: t = '''
    ...: # Header with footnote[^1]
    ...: 
    ...: Lorem Ipsum
    ...: 
    ...: [^1]: footnote text
    ...: '''

In [14]: print(markdown.markdown('[TOC]\n\n' + t, extensions=['markdown.extensions.toc', 'markdown.extensions.footnotes']))
<div class="toc">
<ul>
<li><a href="#header-with-footnote1">Header with footnote1</a></li> <!-- Note the '1' in the header id and more importantly the link text -->
</ul>
</div>
<h1 id="header-with-footnote1">Header with footnote<sup id="fnref:1"><a class="footnote-ref" href="#fn:1" rel="footnote">1</a></sup></h1>
<p>Lorem Ipsum</p>
<div class="footnote">
<hr />
<ol>
<li id="fn:1">
<p>footnote text&#160;<a class="footnote-backref" href="#fnref:1" rev="footnote" title="Jump back to footnote 1 in the text">&#8617;</a></p>
</li>
</ol>
</div>

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4