Difference between revisions of "Template:Categorypage"

From Freephile Wiki
Jump to navigation Jump to search
m (fix typo)
 
(3 intermediate revisions by the same user not shown)
Line 1: Line 1:
'''Please see all the articles in [[:Category:{{PAGENAMEE}}|this category]]'''
+
{{#categorytree:{{{1}}}}}
<includeonly>
+
 
[[Category:{{PAGENAMEE}}]]
 
</includonly>
 
 
<noinclude>
 
<noinclude>
This template is used on an article whose page name is the same as the name of a Category, making it easy for a reader to jump to the category.
+
This template is used within your article to display a Category Tree.  Category Tree is an extension that provides a nice visual formatting and display of the Categories in a clickable tree.  Among other things, Category Tree dresses up the display of [[Special:Categories|Categories]] on this site.
 +
 
 +
== Documentation ==
 +
You can display a Category Tree in your article in three ways:
 +
<ol>
 +
<li>the categorytree tag
 +
<pre><categorytree
 +
mode="parents"
 +
depth="3"
 +
hideroot="on"
 +
hideprefix="categories"
 +
showcount="on"
 +
namespaces="Help Talk 0"
 +
class="sidebarTree"
 +
style="font-size:1.3em;"
 +
id="thisBox">Applications</categorytree>
 +
</pre>
 +
<li>the parser tag
 +
<pre>{{#categorytree:Foo|hideroot|mode=pages}}</pre>
 +
<li>the 'Categorypage' template
 +
<pre>{{Categorypage|Foo}}</pre>
 +
</ol>
 +
 
 +
The third option is intended to be used most, because it's the easiest.
  
It also includes the article in that category, making it easy to jump back to the article from the category page.
+
This wiki is designed so that every major category (of articles) has an article introducing that category.  For example, a major theme of this wiki is "Applications", so there is a category for any article which is about or relates to an Application.  There is also a "First-level" article '''named''' [[Applications]] that introduces the reader to the subject.  Such a high-level overview page should include links to all the articles within the subject matter.  The easy way to make that happen is to use the <pre>{{Categorypage|Foo}}</pre> 'Categorypage' template
 +
 
 +
Under the covers, the Categorypage template implements the CategoryTree extension.  See http://www.mediawiki.org/wiki/Extension:CategoryTree for full details of the extension.
 +
 
 +
== Usage ==
 +
This template is setup to make it even easier to put a CategoryTree on your article.  You just use the template syntax, and give it the argument of the Category you want to show:
 +
e.g.
 +
 
 +
<nowiki>{{Categorypage|Free Software}}</nowiki>
 
</noinclude>
 
</noinclude>
 
[[Category:PAGENAMEE]]
 

Latest revision as of 10:25, 12 January 2016


This template is used within your article to display a Category Tree. Category Tree is an extension that provides a nice visual formatting and display of the Categories in a clickable tree. Among other things, Category Tree dresses up the display of Categories on this site.

Documentation[edit source]

You can display a Category Tree in your article in three ways:

  1. the categorytree tag
    <categorytree
    mode="parents"
    depth="3"
    hideroot="on"
    hideprefix="categories"
    showcount="on"
    namespaces="Help Talk 0"
    class="sidebarTree"
    style="font-size:1.3em;"
    id="thisBox">Applications</categorytree>
    
  2. the parser tag
    {{#categorytree:Foo|hideroot|mode=pages}}
  3. the 'Categorypage' template
    {{Categorypage|Foo}}

The third option is intended to be used most, because it's the easiest.

This wiki is designed so that every major category (of articles) has an article introducing that category. For example, a major theme of this wiki is "Applications", so there is a category for any article which is about or relates to an Application. There is also a "First-level" article named Applications that introduces the reader to the subject. Such a high-level overview page should include links to all the articles within the subject matter. The easy way to make that happen is to use the

{{Categorypage|Foo}}

'Categorypage' template

Under the covers, the Categorypage template implements the CategoryTree extension. See http://www.mediawiki.org/wiki/Extension:CategoryTree for full details of the extension.

Usage[edit source]

This template is setup to make it even easier to put a CategoryTree on your article. You just use the template syntax, and give it the argument of the Category you want to show: e.g.

{{Categorypage|Free Software}}