footnotes

bholt's picture

jQuery Footnotes

jFootnotes is a jQuery plugin that creates and formats footnotes based on inline content. I have used it fairly extensively on this site, and thought I’d share it with the world. It has been tested with jQuery 1.2.6, but I have no reason to believe it won’t work with 1.3.x as well.

Once the module has been included in a page, it can be called as follows:

$("div").footnotes();

Pretty straightforward. By default, it will look for

  • any span elements with the footnotes class, and
  • any blockquote elements with a title attribute

within the outer selection (e.g., within any div elements, in this case). The matches will be extracted and moved to footnotes.

Syndicate content