Template:Mosnav/doc: Difference between revisions

From Tardis Wiki, the free Doctor Who reference
No edit summary
No edit summary
Line 1: Line 1:
'''{{tlx|mosnav}}''' is a template that puts a navigation strip, much like the one used for forum threads, at the top of a page.  It should be used only on pages of the manual of style; hence: '''mos'''nav.   
'''{{tlx|mosnav}}''' is a template that puts a navigation strip, at the top of a page.  It should be used only on pages of the manual of style; hence: '''mos'''nav.   


==Usage==
==Usage==
To use, follow this simple pattern:
To use, follow this simple pattern:
*{{tlx|mosnav|p|1|2|3|4|5|6|7|8|c}}
<pre>{{tlx|mosnav|p=parent chapter name|c=category name}}</pre>
where ''p'' is the parent chapter for all the other pages listed at ''1'', ''2'', ''3'' ... ''19''. All are optional, and if you type {{tlx|mosnav}} alone, it sill simply put the current page in the nav bar like so:
{{mosnav}}
This, however, is not very helpful, because it allows you to navigate only back to the page [[Tardis:Manual of style]].


The variable ''c'' can and should be set to a name for the chapter, so that all pages in that chapter can be organised under a single category.  The resulting category would then go into [[:Category:Manual of style]].
Often, but not always, ''p'' and ''c'' have the same value, as can be seen at [[T:COMMA]].  Both ''p'' and ''c'' must be defined for the template to work properly.


A more full-bodied example of this template is:
The template will produce a navigation scheme which automatically includes all pages in the category specified. 
:{{tt|<nowiki>{{mosnav|p=Wikify wisely|Redlinks|c=wikification}}</nowiki>}}
 
which produces:
== Historical note ==
{{mosnav|Redlinks|p=Wikify wisely|}}
This template was entirely redesigned and automated at 01:47, February 18, 2013 (UTC).  Prior to this date, it was necessary to add each and every page to the template by hand.  Thus, you will still find a number of pages that contain a number of superfluous parameters. '''These do not work''', but it is not imperative to remove them, since they are harmlessThe ''only'' things this template requires are values for ''p'' and ''c''.  
Note that the namespace '''Tardis:''' is already assumedAll you need is the page name, not the ''full'' page name.  Also, see how the current page name, '''Mosnav''', is put into the navigation bar by default.  Obviously, if you were to put this particular example on [[Tardis:Don't over-wikify]], it would make a little more sense.
== Thanks ==
== Thanks ==
This template owes some debt to [[memoryalpha:template:mos nav]] — though not quite so much as the name suggestsThis is basically just an adaptation of the basic {{tlx|forumheader}} template which is a default part of the Wikia MediaWiki installation.
This template's name and earliest function owed a debt to [[memoryalpha:template:mos nav]].  However, its code doesn't barely resembles that MemAlpha template much anymore.  
<noinclude>[[category:template documentation|{{PAGENAME}}]]</noinclude>
<noinclude>[[category:template documentation|{{PAGENAME}}]]</noinclude>

Revision as of 01:47, 18 February 2013

{{mosnav}} is a template that puts a navigation strip, at the top of a page. It should be used only on pages of the manual of style; hence: mosnav.

Usage

To use, follow this simple pattern:

{{tlx|mosnav|p=parent chapter name|c=category name}}

Often, but not always, p and c have the same value, as can be seen at T:COMMA. Both p and c must be defined for the template to work properly.

The template will produce a navigation scheme which automatically includes all pages in the category specified.

Historical note

This template was entirely redesigned and automated at 01:47, February 18, 2013 (UTC). Prior to this date, it was necessary to add each and every page to the template by hand. Thus, you will still find a number of pages that contain a number of superfluous parameters. These do not work, but it is not imperative to remove them, since they are harmless. The only things this template requires are values for p and c.

Thanks

This template's name and earliest function owed a debt to memoryalpha:template:mos nav. However, its code doesn't barely resembles that MemAlpha template much anymore.