Difference between revisions of "Template:Main site"

From GeeklogWiki
Jump to: navigation, search
(Tried a fix)
(Testing)
Line 1: Line 1:
<includeonly>{{#switch:{{{type}}}
+
{{#expr: 1 and -1 }}
|article=http://www.geeklog.net/article.php/{{{id}}}
 
|forum=http://www.geeklog.net/forum/viewtopic.php?showtopic={{{id}}}
 
|#default={{{type}}}}}</includeonly><noinclude>Supply an item type and ID from the main site and get a link for it.
 
 
 
==Usage==
 
<pre><nowiki>{{main site| type=item_type| id=item_id}}</nowiki></pre>
 
 
 
For example, <nowiki>{{main site| type=article| id=2004063013542379}}</nowiki> would display as:
 
 
 
{{main site| type=article| id=2004063013542379}}
 
 
 
<nowiki>{{main site| type=forum| id=87624}}</nowiki> would display as:
 
 
 
{{main site| type=forum| id=87624}}
 
 
 
</noinclude>
 

Revision as of 12:05, 26 May 2009

{{#expr: 1 and -1 }}