> I'd like to create CSS2 footnotes that
> a) are easy for web developers to code,
> b) are auto-numbered, and
> c) only display a number surrounded by brackets most of the
> time, and
> d) only display the footnote when you hover over the number.
> By a), I mean that a developer would only have to do
> <span class="footnote">This is the text that will appear when hovering.</span>
> and it would behave as expected. The first .footnote on the
> page would show only "" until you hoveered, the second
> would display "", and so on.
> Has this already been done?
How would you do the auto numbering in css2? css3, maybe, but css2?
to do is loop through spans, check if one of their classes contain
footnote and replace them with the said number and a title containing
the original text. However, this makes your footnote dependent on a
mouse to make sense to a visual user (screen reader users will have to
have title reading turned on). Wouldn't it make more sense to have the
footnotes as real footnotes in the text with a target and the footnote
links as real links pointing to those targets? Then you can do the
beforementioned, too, but you are not dependent on mouse and hover,
which can be very annoying to read and impossible to copy.
List wiki/FAQ -- http://css-discuss.incutio.com/
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/