|
Cookbook /
FootnotesSummary: Simple footnote markup
Version: 1.0.0
Prerequisites: pmwiki 2.0 and above
Status: Stable
Maintainer: TonyColley
Categories: Markup
Questions answered by this recipeIs there a way to automatically number footnotes and to have them all automatically displayed at the bottom of the page? UsageDownload footnote.phpΔ and place it in your cookbook directory. Add the following line to local/config.php include_once("cookbook/footnote.php");
Wherever you want a footnote in your text, simply use the When you want to display all the footnotes you have so far, below a short blue horizontal rule, use the markup If you do not want the short blue horizontal rule, but just a listing of all the footnotes defined so far, use the markup You may have multiple occurrences of the listing markups; each one will display only the footnotes created in the text since the last listing markup. (So you can have footnotes at the end of each section of your text, for example.) NotesThis recipe was extracted from MarkupExtensions for those of us who just want footnote capability without all the other extensions provided by that recipe. Release NotesCommentsDoes not work with the Confluence script : http://pmwiki.org/wiki/Test/Confluence Profiles.SH - 6 Aug 2007 Just an observation that embedding a link inside the Footnote text works normally in the Simple Footnote, but is not processed by the Extended Footnote and simply appears in full as text, complete with its double square brackets. Des October 07, 2007, at 05:30 PM The code of the footnote script dosen't allow PmWiki to work with CSS pseudo selector: ":target". To highlight some text the text must be betwixt the opening and the closing tags of anchor. I change the lines:
$r = "<sup><a class='footnote' href='#fn$fnid'>$fncount</a></sup>".
"<a name='fnr$fnid' id='fnr$fnid'></a>";
$foottext = stripslashes( $foottext );
$fntext .= "<p class='footnote'><a name='fn$fnid' id='fn$fnid'></a>";
$fntext .= "<sup>$fncount</sup> $foottext <a href='#fnr$fnid'>⇑</a></p>";
to:
$r = "<sup id='fnr$fnid'><a class='footnote' href='#fn$fnid'>[$fncount]</a></sup>";
$foottext = stripslashes( $foottext );
$fntext .= "<p id='fn$fnid' class='footnote'>";
$fntext .= "<sup>$fncount</sup> <a href='#fnr$fnid'>⇑</a> $foottext</p>";
'Tis working only with
:target {
-webkit-animation: highlight 6s 0.1s 1;
-moz-animation: highlight 6s 0.1s 1;
-ms-animation: highlight 6s 0.1s 1;
-o-animation: highlight 6s 0.1s 1;
animation: highlight 6s 0.1s 1;
}
@-webkit-keyframes highlight {
0% { background-color: red; }
100% { background-color: white; }
}
@-moz-keyframes highlight {
0% { background-color: red; }
100% { background-color: white; }
}
@-ms-keyframes highlight {
0% { background-color: red; }
100% { background-color: white; }
}
@-o-keyframes highlight {
0% { background-color: red; }
100% { background-color: white; }
}
@keyframes highlight {
0% { background-color: red; }
100% { background-color: white; }
}
Jl Alice - 16 May 2013 See Also
Contributors
User notes +2: If you use, used or reviewed this recipe, you can add your name. These statistics appear in the Cookbook listings and will help newcomers browsing through the wiki. |