Template:ShowSec/doc

From Uncyclopedia, the content-free encyclopedia
Jump to navigation Jump to search
This is a documentation subpage for Template:ShowSec.
It contains usage information, categories and other content that is not part of the original template page.
To view the template page itself, see Template:ShowSec.

Description

This template uses a numerical index to extract a page section (without the header). It is especially useful for CGI UnGames, where the {{Get}} template uses numbers anyway.

For other purposes, editors may be more interested in an alternative method using section titles instead.

Usage

{{ShowSec|page|section number}}
Special section numbers
Section number Result
0 Displays the section of the page prior to the first header
-1 Displays the last section of the page (-2 cannot be used to display the second last section, and so on)
no number input Treated as though it were section 0

See also

Alternative

Described by WP:SELECTIVETRANSCLUSION, the syntax is {{#section-h:page|section name}}. If we assume the first section of Uncyclopedia:How To Be Funny And Not Just Stupid is entitled "Understand the big picture", these two statements are equivalent:

  • {{ShowSec|UN:HTBFANJS|1}}
  • {{#section-h:UN:HTBFANJS|Understand the big picture}}

Notice that a colon separates section-h from the page name, not a pipe.