Difference between revisions of "Template:forumlink"

(Initial Version)
 
m (Hopefully removes inappropriate return elsewhere)
 
(2 intermediate revisions by one other user not shown)
Line 1: Line 1:
 
<noinclude>
 
<noinclude>
a small template to link to a post on the forum. it (should be) template safe, thats why I'm making it.
+
A small template to link to a post on the forum. it (should be) template safe, that's why I'm making it.
</noinclude>
 
  
<includeonly>
+
its a basic template that takes two key parms, and one optional parm as follows.
[http://love2d.org/forums/viewtopic.php?f={{{forum|3}}}&t={{{topic|}}} {{{title|<sup>#{{{topic}}}</sup> }}}]
+
 
</includeonly>
+
Given the link:
 +
:<tt><nowiki>http://love2d.org/forums/viewtopic.php?f=4&t=1623</nowiki></tt>
 +
 
 +
The template should be called as:
 +
:<tt><nowiki>{{forumlink|forum=4|topic=1623}}</nowiki></tt>
 +
Resulting in:
 +
:{{forumlink|forum=4|topic=1623}}
 +
 
 +
We can add the optional <tt>title</tt> parm to give it a nicer name:
 +
:<tt><nowiki>{{forumlink|forum=4|topic=1623|title=the ulove thread on the forums}}</nowiki></tt>
 +
Resulting in:
 +
:{{forumlink|forum=4|topic=1623|title=the uLove thread on the forums}}
 +
 
 +
</noinclude><includeonly>[http://love2d.org/forums/viewtopic.php?f={{{forum|}}}&t={{{topic|}}} {{{title|<sup>#{{{topic}}}</sup> }}}]</includeonly>

Latest revision as of 06:07, 10 August 2011

A small template to link to a post on the forum. it (should be) template safe, that's why I'm making it.

its a basic template that takes two key parms, and one optional parm as follows.

Given the link:

http://love2d.org/forums/viewtopic.php?f=4&t=1623

The template should be called as:

{{forumlink|forum=4|topic=1623}}

Resulting in:

#1623

We can add the optional title parm to give it a nicer name:

{{forumlink|forum=4|topic=1623|title=the ulove thread on the forums}}

Resulting in:

the uLove thread on the forums