Coding with SPIP 3.0
SPIP3.0 Technical Documentation

> > > > Contents of parent loops

Contents of parent loops

Sometimes it’s useful to retrieve contents from a loop which is a parent of the current loop, just by using an ordinary SPIP tag. SPIP offers a special syntax to do this explicitly with the # symbol, by simply identifying which loop you wish to retrieve the data from (where n below is the identifier of the targeted loop):

  1. #_n:TAG


Display the title of the section (rubrique) beside the title of the current article:

  2. <ul>
  3. <BOUCLE_arts(ARTICLES){id_rubrique}>
  4. <li>#_rubs:TITRE - #TITRE</li>
  5. </BOUCLE_arts>
  6. </ul>
  7. </BOUCLE_rubs>