#EXPOSE

#EXPOSE is used to Emphasise one particular entry within a list. When we loop on a table and the #ENV{id_table} tag has a value within the current environment, or there is an #ID_TABLE in a higher level loop, then #EXPOSE will return a special code when the loop hits the same value as the identifier.

Its syntax is:

  1. #EXPOSE{text if yes}
  2. #EXPOSE{text if yes, text if no}
  3. // expose with no parameters returns 'on' if yes or the empty string '' if no
  4. #EXPOSE

Download

Example

List the articles in the current section, and assign the CSS class "on" for the current article.

  1. <ul>
  2. <BOUCLE_arts(ARTICLES){id_rubrique}{par num titre, titre}>
  3. <li[ class="(#EXPOSE{on})"]>#TITRE</li>
  4. </BOUCLE_arts>
  5. </ul>

Download

Results:

  1. <ul>
  2. <li>#AUTORISER</li>
  3. ...
  4. <li>#ENV</li>
  5. <li>#EVAL</li>
  6. <li class="on">#EXPOSE</li>
  7. ...
  8. </ul>

Download

Author Mark Baber Published : Updated : 11/06/10

Translations : English, français