Jump to content

User:Blue-Haired Lawyer/Footnote popups

From Wikipedia, the free encyclopedia

Footnote Popups is a relatively simple Javascript which floats a small box with a footnote's content on top of a footnote link whenever a user hovers their cursor over it.


Installation

[edit]

To install the script just add the following line to Special:MyPage/skin.js (applies to the currently selected skin) or Special:MyPage/common.js (applies to all skins)

importScript("User:Blue-Haired Lawyer/footnote popups.js");

or if you want to use the script on a MediaWiki wiki other than the English Wikipedia:

importScriptURI("http://en.wikipedia.org/w/index.php?title=User:Blue-Haired_Lawyer/footnote_popups.js&action=raw&ctype=text/javascript");

Like other Javascripts, you'll have to purge your browser cache (Ctrl+F5 in most browsers) before the changes take effect.


Programming stuff

[edit]

Footnote Popups works with Cite footnotes using <ref>...</ref> tags; see Help:footnotes.

Footnote Popups will also work with templates that create anchors with names beginning with

cite_note-listref-

See {{Listref}} for an example.


Author notes

[edit]

I've tested the script in Firefox 2 and 3, Internet Explorer 6 and 7, and Safari 3. If it works / doesn't work for other browsers, please let me know. — Blue-Haired Lawyer 12:34, 22 February 2009 (UTC)

I've decided to stop support for Internet Explorer 6. I find it difficult to find a computer which still runs it, Microsoft have made it impossible to debug JavaScript errors on it and frankly, and perhaps most importantly, it's a bit shit. — Blue-Haired Lawyer 11:38, 10 March 2009 (UTC)