I'm actually not sure Wikimedia's footnote code allows for this, but I was wondering if it would be possible to add a way to reference the same footnote twice. Id est, if I use <fn>Space</fn>, <fn>Time</fn>, and then <fn>Space</fn> again in a paragraph, it will list "Space" twice instead of condensing it into one reference. I can't say what the best solution is. The obvious one is to make it so that identical footnotes are condensed into one since I can't think of a reason why someone would want the same footnote listed twice. Thanks in advanced.


beginner’s picture

I have been thinking about this feature.
On the face of it, it looks reasonable, but then we run into problems of implementation.

* 1st scenario: we assume the user doesn't need to enter twice the same footnote. He would only need to enter a reference to an existing footnote. --> Here we have a big implementation problem, since the footnotes are numbered on the fly. The numbering is not fixed, i.e. if you add another footnote at the beginning, all the footnotes would be renumbered. Or the only way would be to add a very complex cross-referencing system between footnotes (letting the users give an id to each footnote). This scenario is neither simple at the code level, nor at the useability level.

* 2nd scenario: as in Kripsy's example, the same footnote is entered twice, exactly the same, and the module notices the duplication and references the second identical footnote to the previous one. Although technically easier to implement, we loose at least half of the convenience of having duplicated footnotes: the user still has to enter the same text twice. Any slight difference (like an extra space) would fool the module into thinking they are different footnotes, and confuse the user into thinking the module doesn't work.
Also with this scenario, we run into scalability issues. I don't like adding more things to compute during a node view operation (filter modules all operate during a node view operation). Viewing nodes is by far the most common task in any site, and any added complexity in rendering a node has a performance hit. Having said that, I am not too sure how the cache mechanism works with filtered text, for *authenticated* users, i.e. I don't know if there is any caching done at all. If there is no caching done, any extra computing we add would be done each time an authenticated user is viewing a node! So, we might want to be careful in adding such features.

* 3rd scenario: we change nothing and we use footnotes as in the "real" world, i.e. in the world of paper books. If you've read any heavily referenced book, you'd have noticed that the author would often quote from the same book again and again. This is a situation where there are many similar footnotes. You would have noticed that they never reference the same footnote twice, but use text like: Ibid. p23, which is shorthand for: same reference as footnote above, page 23

I vote for the 3rd scenario, i.e. won't fix.

If someone provides a patch, I'll still review it. Hingo will take the final decision.

Kripsy’s picture

After reading your logic I can't help but see your point of view. I'm not sure how much checking for duplicates would bog down the node rendering but using proper citation is certainly a more proper answer.

hingo’s picture

Title:Reference the Same Footnote Twice» Reference the Same Footnote Twice: Use "Ibid."
Status:Active» Closed (won't fix)

Good suggestion and analysis. I agree with what has been said.

There is also a third option. We could add a possibility for the user to define the id that is now randomly generated in and attribute to the footnote tag. So:

First footnote is normal and works like currently.<fn>first footnote</fn>

Second footnote defines it's own id.<fn fn-id="fnlink1">second footnote</fn>

Third footnote uses the same id, so it links to the same footnote using the same number. No text is necessary inside the fn tags, text is take from the first occurence.<fn fn-id="fnlink1"></fn>

This would be reasonable to implement in terms of workload. Still, having myself written the example above, it doesn't feel like something nice and convenient I'd like to use. I'd still rather prefer the "Ibid" style.

I will close this as won't fix. If someone really comes with a good patch, I won't reject it though.