Wikibooks:Templates/General

From Wikibooks, the open-content textbooks collection

Jump to: navigation, search
Module contents Maintenance [edit] Wikibooks community

General | Sources | Links | Navigation | Files | Media files

Maintenance | Licensing notices | Deletion

Users | User notices | Project

Contents

[edit] Notices

Markup Display
{{wrongtitle|title=Title}}
The title given to this book is incorrect due to technical limitations. The correct title is Title.

There is also the {{incomplete}} template. While there may be justified usages for this, be advised against using it whenever text should be expanded on. Be specific in what is lacking to make collaboration easier and inform readers. Maybe you are looking for {{TODO}} or one of the templates listed on Help:Stub. Some wikibooks have book-specific to-do templates such as {{Japanese todo}}.

The {{spoiler}} and {{endspoiler}} templates came with the Muggles' Guide to Harry Potter from Wikipedia. While there was a case for using it there (encyclopaedia articles contain various information and some are looking for general information but others synopses) try to do without in your wikibooks. Place spoiling content is separate modules and alert readers before they go there.

[edit] Images

See also mw:Help:Images for more on the image formatting syntax, and Help:Uploading images for help on uploading images on Wikibooks.

Images can be made to link to somewhere else than the image description page by specifying the link variable. The {{click}} template allows for setting the "title" attribute of the link element through its alt variable.

Markup Display
[[Image:Wikibooks-logo.svg|40px|link=Main Page]] Wikibooks-logo.svg
{{click|image=Wikibooks-logo.svg|width=40px|height=40px|link=Main Page|alt=The Wikibooks main page.}}
Main Page

[edit] Page details

The {{Displaytitle}} template can set the page title and tab. The former is useful for modifying page titles to something not possible due to technical limitations. The latter is used in the Cookbook to differentiate between recipes and ingredients. See the template page for documentation.

[edit] Text boxes

Maybe this should better belong on a seperate page... --Swift (talk) 05:42, 27 January 2009 (UTC)

[edit] Generic text boxes

These text box templates are used to set aside a block of text from the rest of the page.

Markup Display
{{SideBox|Text}}
  • Floats on the right
  • Text is centered
  • 250px wide
Text
{{LeftBox|Text}}
  • Floats on the left
  • Text is centered
  • 250px wide
Text
{{LeftHalf|Text}}
  • Floats on left
  • 50% of screen width
Text
{{RightHalf|Text}}
  • Floats on right
  • 50% of screen width
Text
{{TextBox|Text}}
  • 100% of screen width

Text

{{DropBox|Caption|Text}}
  • Same format as previous text boxes, but can be shown or hidden
  • Adjustable width/floating (see examples at Template:DropBox)
{{Body note|a short text in the body text}} A paragraph
Note

a short text in the body

A paragraph of main text
{{Side note|a short text on left}}
a short text on left
A paragraph of main text
{{Side note|side=right|a short text on right}}
a short text on right
A paragraph of main text

[edit] Formatted text boxes

Markup Display
{{message box|heading=You should contribute to Wikibooks.|message=Wikibooks is a collection of free textbooks that anyone can edit.}}
logo You should contribute to Wikibooks.
Wikibooks is a collection of free textbooks that anyone can edit.
{{message box|image=stop_hand.png|alt=stop sign|backgroundcolor=yellow|heading=You can change the image and background color.|message=This template has optional parameters.}}
stop sign You can change the image and background color.
This template has optional parameters.

[edit] Specialised text boxes

These templates make it easy to quickly add formatting to your wikibooks. Should you wish to modify them, please try not to do so in a backwards incompatible fashion as they are used across a number of different books.

Markup Display
{{Example|example text}}
Example
Example:

example text

{{Proof|proof text}}
Proof: proof text
{{Helpful hint}}
Helpful Hint!
Give a hint here
{{Warning|warning text}}
{{Yellow Warning|warning text}}
{{Info|information}}
Information

information

{{SAMPLE|caption=Caption|sampletext=Some sample text.}}
In other languages