Extension:ConditionalContent

Purpose
Provides parser functions #cc and #ccd for controlling the conditional inclusion of pages.

Features

 * Secure:
 * The user must have the read right to the target pages (i.e. page_true and page_false)
 * Dynamic
 * Integration with Extension:ParserPhase2
 * Flexible comparaison mechanism

#cc

 * Where page_true corresponds to the page to include when condition==comparator
 * Where page_false corresponds to the page to include when condition!=comparator
 * Where page_false corresponds to the page to include when condition!=comparator

#ccd
The following parser-function is really meant to be used in conjunction with Extension:ParserPhase2. The same parameters as #cc apply to #ccd. The use of ParserPhase2 enables the dynamic inclusion of page content whilst still preserving the virtues of parser-caching for both the source and target pages.

(($#ccd|page_true|condition|comparator|page_false$))

Examples

 * Assuming that the page Extension:ConditionalContent_testpage_true contains the text true
 * Assuming that the page Extension:ConditionalContent_testpage_false contains the text false

Example1
The text following the semicolon should read true :

Example2
The text following the semicolon should read false :

Dependancies

 * StubManager extension
 * ParserPhase2 is only required for #ccd.