Template:Prevnext: Difference between revisions

From KDE UserBase Wiki
(Removed Translate tags)
No edit summary
Line 4: Line 4:
|}</includeonly>
|}</includeonly>
<noinclude>
<noinclude>
Use this template when you want to provide links to the previous and the next sections of the article so the user isn't forced to go back to the index to navigate.  
Use this template when you want to provide links to the previous and the next sections of the article so the user isn't forced to go back to the index to navigate.  


== How to use this template ==  
== How to use this template ==  


Write <tt>'''<nowiki>{{Prevnext|Go back a page|The next section is difficult!}}</nowiki>'''</tt>, which will be returned as,
Write  
 
{{Input|1=<nowiki>{{Prevnext|Go back a page|The next section is difficult!}}</nowiki>}}
You will get this:
{{Prevnext|Go back a page|The next section is difficult!}}
{{Prevnext|Go back a page|The next section is difficult!}}


== Prettier links ==  
== Prettier links ==  
To make the links to the pages look less ugly you can provide extra options to the template:
To make the links to the pages look less ugly you can provide extra options to the template:
 
{{Input|1=<nowiki>{{Prevnext|Article/section/previous-subsection|Article/section/next|This points to the previous section text|This is the next section}}</nowiki>}}
'''<tt><nowiki>{{Prevnext</nowiki><br><nowiki>
|Article/section/previous-subsection   |Article/section/next| </nowiki><br><nowiki>
This points to the previous section text   | This is the next section</nowiki><br><nowiki>
}}</nowiki></tt>'''
 
 
This will be rendered as
This will be rendered as
{{Prevnext|Article/section/previous-subsection|Article/section/next|This points to the previous section|This is the next section}}
{{Prevnext|Article/section/previous-subsection|Article/section/next|This points to the previous section|This is the next section}}
==Only one direction==
'''<tt><nowiki>{{Prevnext</nowiki><br><nowiki>
||Article/section/next| </nowiki><br><nowiki>
|| This is the next section</nowiki><br><nowiki>
}}</nowiki></tt>'''
This will be rendered as
{{Prevnext||Article/section/next||This is the next section}}


== See also ==
== See also ==
Line 41: Line 24:
* [[Template:Next|Next]] - For providing a link to the next article. Use for the first article page.
* [[Template:Next|Next]] - For providing a link to the next article. Use for the first article page.
* [[Template:Prev|Prev]] - For providing a link to the previous article. Use for the last article page.
* [[Template:Prev|Prev]] - For providing a link to the previous article. Use for the last article page.


[[Category:Template]]
[[Category:Template]]
</noinclude>
</noinclude>

Revision as of 17:21, 11 September 2010


Use this template when you want to provide links to the previous and the next sections of the article so the user isn't forced to go back to the index to navigate.

How to use this template

Write

{{Prevnext|Go back a page|The next section is difficult!}}

You will get this:

Previous
Go back a page
Next
The next section is difficult!


Prettier links

To make the links to the pages look less ugly you can provide extra options to the template:

{{Prevnext|Article/section/previous-subsection|Article/section/next|This points to the previous section text|This is the next section}}

This will be rendered as

Previous
This points to the previous section
Next
This is the next section


See also

  • Next - For providing a link to the next article. Use for the first article page.
  • Prev - For providing a link to the previous article. Use for the last article page.