Template:Link/Doc

From PCSAR

(Difference between revisions)
Jump to: navigation, search

Brett Wuth (Talk | contribs)
(New page: This template is used to create a link to a page. It's purpose is very similar to creating links with double square brackets. The benefit of using <code>{{((}}link|</code> is that if a d...)
Next diff →

Revision as of 02:51, 7 February 2012

This template is used to create a link to a page.

It's purpose is very similar to creating links with double square brackets.

The benefit of using {{link| is that if a description is not provided the link defaults to the description the page provides by using Template:desc, etc.

Just like with double square brackets, if you have preferred text for the link, you can provide it.


For illustration, suppose we have two pages:


You type... You get...
{{link|Demo/Page with description}} 
Described page
{{link|Demo/Page without description}} 
Page without description
{{link|Demo/Page with description|this page}} 
this page
{{link|Demo/Page without description|this page}} 
this page


Here's how it would work if you had used square brackets instead:

You type... You get...
[[Demo/Page with description]] 
Demo/Page with description
[[Demo/Page without description]] 
Demo/Page without description
[[Demo/Page with description|this page]] 
this page
[[Demo/Page without description|this page]] 
this page

The difference is only in the first case.