Template:APIOverviewBox/documentation: Difference between revisions

From ReliaWiki
Jump to navigation Jump to search
No edit summary
No edit summary
Line 17: Line 17:


<pre>
<pre>
{{Template:APIOverviewBox
{{APIOverviewBox
|Main_Page|Box Title
|Main_Page|Box Title
|Text to describe the box.
|Text to describe the box.
Line 24: Line 24:


The output of this code is as follows. Clicking anywhere within the box will take you to the main page of ReliaWiki (called "Main_Page"):
The output of this code is as follows. Clicking anywhere within the box will take you to the main page of ReliaWiki (called "Main_Page"):
{{Template:APIOverviewBox
{{APIOverviewBox
|Main_Page|Box Title
|Main_Page|Box Title
|Text to describe the box.
|Text to describe the box.
Line 36: Line 36:
<!--- Row 1 --->
<!--- Row 1 --->
<div style="clear:both;">
<div style="clear:both;">
{{Template:APIOverviewBox
{{APIOverviewBox
|Main_Page|Box Title 1
|Main_Page|Box Title 1
|Text to describe the box.
|Text to describe the box.
}}
}}


{{Template:APIOverviewBox
{{APIOverviewBox
|Main_Page|Box Title 2
|Main_Page|Box Title 2
|Text to describe the box.
|Text to describe the box.
Line 49: Line 49:
<!--- Row 2 --->
<!--- Row 2 --->
<div style="clear:both;">
<div style="clear:both;">
{{Template:APIOverviewBox
{{APIOverviewBox
|Main_Page|Box Title 3
|Main_Page|Box Title 3
|Text to describe the box.
|Text to describe the box.
}}
}}


{{Template:APIOverviewBox
{{APIOverviewBox
|Main_Page|Box Title 4
|Main_Page|Box Title 4
|Text to describe the box.
|Text to describe the box.
Line 65: Line 65:
<!--- Row 1 --->
<!--- Row 1 --->
<div style="clear:both;">
<div style="clear:both;">
{{Template:APIOverviewBox
{{APIOverviewBox
|Main_Page|Box Title 1
|Main_Page|Box Title 1
|Text to describe the box.
|Text to describe the box.
}}
}}


{{Template:APIOverviewBox
{{APIOverviewBox
|Main_Page|Box Title 2
|Main_Page|Box Title 2
|Text to describe the box.
|Text to describe the box.
Line 78: Line 78:
<!--- Row 2 --->
<!--- Row 2 --->
<div style="clear:both;">
<div style="clear:both;">
{{Template:APIOverviewBox
{{APIOverviewBox
|Main_Page|Box Title 3
|Main_Page|Box Title 3
|Text to describe the box.
|Text to describe the box.
}}
}}


{{Template:APIOverviewBox
{{APIOverviewBox
|Main_Page|Box Title 4
|Main_Page|Box Title 4
|Text to describe the box.
|Text to describe the box.

Revision as of 15:37, 24 November 2015


Template Documentation

This template creates a fixed-sized, clickable <div> box. Use this template to create a navigational grid on a wiki page.

Usage

This template has three required parameters:

1 = The name of the wiki page to link to.
2 = The title of the box.
3 = The description for the box.

Example 1

The following code sample shows a box that links to the main page of ReliaWiki.

{{APIOverviewBox
|Main_Page|Box Title
|Text to describe the box.
}}

The output of this code is as follows. Clicking anywhere within the box will take you to the main page of ReliaWiki (called "Main_Page"):

{{{title}}}

{{{links}}}

Example 2

To create a 2 x 2 grid, wrap each row of boxes in a <div> "wrapper" that clears all floating elements on both sides.

<!--- Row 1 --->
<div style="clear:both;">
{{APIOverviewBox
|Main_Page|Box Title 1
|Text to describe the box.
}}

{{APIOverviewBox
|Main_Page|Box Title 2
|Text to describe the box.
}}
</div>

<!--- Row 2 --->
<div style="clear:both;">
{{APIOverviewBox
|Main_Page|Box Title 3
|Text to describe the box.
}}

{{APIOverviewBox
|Main_Page|Box Title 4
|Text to describe the box.
}}
</div>

The output is as follows:

{{{title}}}

{{{links}}}


{{{title}}}

{{{links}}}

{{{title}}}

{{{links}}}


{{{title}}}

{{{links}}}