Difference between revisions of "Template:FAQ page"

From blackwiki
Jump to navigation Jump to search
imported>SMcCandlish
(typo)
imported>SMcCandlish
(Tweak; doc update)
Line 4: Line 4:
 
|imageright = {{#if:{{{shortcut|{{{shortcut1|{{{sc1|{{{1<includeonly>|</includeonly>}}}}}}}}}}}} |{{shortcut|{{{shortcut|{{{shortcut1|{{{sc1|{{{1}}}}}}}}}}}}|{{{shortcut2|{{{sc2|{{{2|}}}}}}}}}|{{{shortcut3|{{{sc3|{{{3|}}}}}}}}}|{{{shortcut4|{{{sc4|{{{4|}}}}}}}}}|{{{shortcut5|{{{sc5|{{{5|}}}}}}}}}<noinclude>|category=no</noinclude>}} }}
 
|imageright = {{#if:{{{shortcut|{{{shortcut1|{{{sc1|{{{1<includeonly>|</includeonly>}}}}}}}}}}}} |{{shortcut|{{{shortcut|{{{shortcut1|{{{sc1|{{{1}}}}}}}}}}}}|{{{shortcut2|{{{sc2|{{{2|}}}}}}}}}|{{{shortcut3|{{{sc3|{{{3|}}}}}}}}}|{{{shortcut4|{{{sc4|{{{4|}}}}}}}}}|{{{shortcut5|{{{sc5|{{{5|}}}}}}}}}<noinclude>|category=no</noinclude>}} }}
 
}}{{#ifeq:{{{demo}}}|yes||<includeonly>{{#switch:{{NAMESPACE}}
 
}}{{#ifeq:{{{demo}}}|yes||<includeonly>{{#switch:{{NAMESPACE}}
  |{{ns:0}} = {{{category|[[Category:Wikipedia article FAQs|{{PAGENAME}}]]}}}
 
 
   |{{ns:1}} = {{{category|[[Category:Wikipedia article FAQs|{{PAGENAME}}]]}}}
 
   |{{ns:1}} = {{{category|[[Category:Wikipedia article FAQs|{{PAGENAME}}]]}}}
 
   |{{ns:4}} = {{{category|[[Category:Wikipedia FAQs|{{PAGENAME}}]]}}}
 
   |{{ns:4}} = {{{category|[[Category:Wikipedia FAQs|{{PAGENAME}}]]}}}
Line 29: Line 28:
  
 
{{Documentation|content=This page-top banner template is for Wikipedia-internal [[FAQ]] pages.
 
{{Documentation|content=This page-top banner template is for Wikipedia-internal [[FAQ]] pages.
 +
 +
==Usage==
 +
For a stand-alone FAQ page: {{tnull|FAQ page}}
 +
 +
For such a page with shortcuts: {{tnull|FAQ page|WP:SC1|WP:SC2}}
 +
 +
For a FAQ that is intended to be transcluded into another page:  <code><nowiki><noinclude>{{FAQ page}}</noinclude></nowiki></code> (this will suppress display of this banner in the transcluding page, but preserve it and its auto-categorization on the FAQ's own page).
 +
 +
This template categorizes pages into one of the following categories, depending on the [[WP:NAMESPACE|namespace]] the template is used in:
 +
 +
* [[:Category:Wikipedia article FAQs]] (when used in the "Talk" namespaces)
 +
* [[:Category:User essays]] (when used in the "User" or "User talk" namespaces)
 +
* [[:Category:Wikipedia FAQs]] (which used in the "Wikipedia", "Wikipedia talk", "Help", "Help talk", and many other functional namespaces and their talk sub-namespaces)
 +
 +
It will not be categorized at all if mistakenly put into a namespace that should not contain such a page, e.g. the main (article) namespace, "Module", "File", "Mediawiki", and some others.  It might be best if the template threw a big red error in such a case, but it is not presently coded to do so.
 
}}
 
}}
 
[[Category:Wikipedia header templates ]]
 
[[Category:Wikipedia header templates ]]
 
[[Category:Wikipedia FAQs|Wikipedia FAQs]]
 
[[Category:Wikipedia FAQs|Wikipedia FAQs]]
 
</noinclude>
 
</noinclude>

Revision as of 03:33, 24 December 2016

Template documentation

This page-top banner template is for Wikipedia-internal FAQ pages.

Usage

For a stand-alone FAQ page: {{FAQ page}}

For such a page with shortcuts: {{FAQ page|WP:SC1|WP:SC2}}

For a FAQ that is intended to be transcluded into another page: <noinclude>{{FAQ page}}</noinclude> (this will suppress display of this banner in the transcluding page, but preserve it and its auto-categorization on the FAQ's own page).

This template categorizes pages into one of the following categories, depending on the namespace the template is used in:

It will not be categorized at all if mistakenly put into a namespace that should not contain such a page, e.g. the main (article) namespace, "Module", "File", "Mediawiki", and some others. It might be best if the template threw a big red error in such a case, but it is not presently coded to do so.