#NOTES
displays the footnotes (collected at the bottom of the page) which have been calculated during the display of the preceding tags. Whenever a tag, for which we calculate SPIP links using the
propre
filter or using another automatic process, contains some footnotes, these notes will be displayed by the
#NOTES
tag once they have all been calculated.
[(#BALISE|propre)]
#TEXTE
#NOTES
{{{Details about footnotes}}}
It is the
traiter_raccourcis()
function called by the
propre
filter which executes the (
inc_notes_dist()
function in the
ecrire/inc/notes.php file, which temporarily stores the notes in memory. When the
#NOTES
tag is actually called, these notes are returned and then emptied from memory.
Say there is some text in the "Standfirst introduction" and more in the "Text" body of a given article as shown below:
// Introductory text:
In the intro, there is one [[Note A]] and another note [[Note B]]
// Main text:
In the text, there is one [[Note C]] and another note [[Note D]]
When the template is displayed, the two code examples below will generate different contents. The first will display all of the notes together, numbered from 1 to 4, after the contents of the text:
<BOUCLE_art(ARTICLES){id_article}>
#CHAPO
#TEXTE
#NOTES
</BOUCLE_art>
In the second example below, the notes of the "intro" are displayed first (numbered from 1 to 2), immediately after the contents of the
#CHAPO
tag, and then the notes from the text (also numbered from 1 to 2), are displayed after the contents of the
#TEXTE
tag:
<BOUCLE_art(ARTICLES){id_article}>
#CHAPO
#NOTES
#TEXTE
#NOTES
</BOUCLE_art>
Example
Calling the notes is often done after all the other fields for an article, which will take into consideration all the notes that have been calculated. Displaying them is quite simple:
[<div class="notes"><h2><:info_notes:></h2>(#NOTES)</div>]