Difference between revisions of "Template:NavHome"

From PC-BSD Wiki
Jump to: navigation, search
(26 intermediate revisions by one user not shown)
Line 1: Line 1:
{{DISPLAYTITLE:<span style="display:none">{{FULLPAGENAME}}</span>}}
+
{| class="navheader noprint screen" style="background: #ffF0F0; border-bottom: #aaaaaa solid 1px; border-collapse:collapse; align:center; margin-left:0; margin-right:0; width:100%;"
{|style="background: #ffF0F0; border-bottom: #ffB5B5 solid 2px; border-top: #ffffff solid 2px; align:center; border-collapse: collapse; margin-top:-20px; margin-left:0; margin-right:0; width:100%;"
+
|class="navleft" style="width: 128px;"| <!-- Always: 'back link', 'forward link', localized 'back link', localized 'forward link' -->
|style="width: 32px;"|
+
|class="navheaderbuffer" style="width: 45%; text-align: left; font-weight: bold; color: #8F80fd;"|
|style="width: 45%; text-align: left; font-weight: bold; color: #8F80fd; border: 0px #000000 solid;"|
+
|class="navmiddle" style="width: 128px;"|[[File:Placeholder.png|class=navheader home|link={{{url|Main Page}}}{{putLang}}|{{#if: {{getLang}}|{{:Translations:{{#titleparts: {{{url|Main Page}}}|1|1}}/Page display title/{{getLang}}|{{{txt|}}}}}}}]]
|style="width: 32px;"|{{template:NavHeaderMiddle}}
+
|class="navheaderbuffer" style="width: 45%; text-align: right; font-weight: bold; color: #8F80fd;"|
|style="width: 45%; text-align: right; font-weight: bold; color: #8F80fd; border: 0px #000000 solid;"|
+
|class="navright" style="width: 128px;"| <!-- Always: 'back link', 'forward link', localized 'back link', localized 'forward link' -->
|style="width: 32px;"|
+
|-
|}
+
|style="background: #FFFFFF; border-top: #ffB5B5 solid 2px; height: 40px;" colspan=5|<span target="{{PAGENAME}}"; id="{{PAGENAME}}"; style="margin-left:0; margin-right:0; width:100%; font-size: 200%; line-height: 1.2em; margin-bottom: 0em;">{{#if: {{getLang}}|{{:Translations:{{#titleparts: {{PAGENAME}}|1|1}}/Page display title/{{getLang}}}}|{{#titleparts: {{{custompagename|{{PAGENAME}}}}}|1}}}}</span>
{|style="border-collapse: collapse; border-bottom: #aaaaaa solid 1px; margin-top:10px; margin-left:0; margin-right:0; width:100%;"
+
|}{{DISPLAYTITLE:<span class="hide_stuff">{{FULLPAGENAME}}</span>}}
|<span target="{{PAGENAME}}"; id="{{PAGENAME}}"; style="font-size: 200%; line-height: 1.2em; margin-bottom: 0.1em;">{{{custompagename|{{PAGENAME}}}}}</span>
+
{| class="noprint" align="left" style="margin-left:-7px; margin-right:20px; margin-top:2px; margin-bottom:1px"
|}
+
{| align="left" style="margin-left:-7px; margin-right:20px; margin-top:2px; margin-bottom:1px"
+
 
|
 
|
 
|-
 
|-
 
|__FORCETOC__
 
|__FORCETOC__
 
| __TOC__  
 
| __TOC__  
|}<includeonly>[[category:{{{custompagename|{{PAGENAME}}}}}]]</includeonly><br>
+
|}<br><noinclude>
<noinclude>
+
[[category:navigation]][[category:templates]]
+
 
__NOEDITSECTION__
 
__NOEDITSECTION__
 
=== Description ===
 
=== Description ===
Line 23: Line 19:
 
===Usage===
 
===Usage===
 
'''<nowiki>{{</nowiki>NavHome|custompagename='''''<custom page name>'''''}}'''
 
'''<nowiki>{{</nowiki>NavHome|custompagename='''''<custom page name>'''''}}'''
</noinclude>
+
[[Category:Navigation]][[category:templates]]
[[Category:Uses NavHome]]<!-- intentionally allowing transclusion -->
+
</noinclude>[[category:Uses NavHome]][[category:{{#titleparts: {{{custompagecategory|{{{custompagename|{{PAGENAME}} }}} }}}|1|1}}]][[category:{{#if: {{#titleparts: {{{custompagecategory|{{{custompagename|{{PAGENAME}} }}} }}}|1|2}}|{{#titleparts: {{{custompagecategory|{{{custompagename|{{PAGENAME}} }}} }}}|1|2}}|{{{custompagecategory|{{{custompagename|{{PAGENAME}} }}} }}} }}]]<!-- allowing transclusion *** no spaces or text beyond this line -->

Revision as of 23:17, 5 November 2013

Contents


Description

This assumes local links and greatly simplifies the process of adding or editing the navigation header for non-handbook pages. As you can see from the above, the navigation header overlays the page name, while a duplicate page name is placed below. The contents box is forced to appear in all pages that contain at least one header and is placed to the left beneath the line of the page name. An alternative page name is an option with the custompagename variable assignment. The home/index link should be modified within the Template:NavHeaderMiddle itself, while below may be pasted into a page with minor modifications to define what will become each link and the text for each link's alternate label. Missing or malformed link info defaults to a Navigation Header error page while properly formed but links to missing pages are added to the Special:wanted pages list. Text ought to be formatted with desired capitalization.

Usage

{{NavHome|custompagename=<custom page name>}}

Personal tools
Namespaces

Variants
Actions
Navigation
Toolbox