"Magnus Manske" <magnusmanske(a)googlemail.com> wrote
in message
news:fab0ecb70709221232i5884e7d6wc7b42235d15e2894@mail.gmail.com...
I have checked in a dead-simple extension
"TemplateLink". It should
solve the ISSN issue (and maybe become a replacement for ISBN as
well?), and potentially many more.
Linking to Special:TemplateLink, you can pass a template with
parameters as parameter. The separators "|" of the template have to be
replaced with "::", otherwise the parser will mess up (or I'll have to
mess up the parser;-)
Example:
[[Special:TemplateLink/test::param1=value1::param2=value2]]
links to a special page that will display "Test" (variation
configurable in i18n) as title and
{{test|param1=value1|param2=value2}}
as content.
That seems horrifically complex!
Can't we just re-use our existing link syntax?
e.g.
1) {{test|param1=value1|param2=value2}} - include the template
2) [[Template:test]] - link to the template.
3) [[Template:test|param1=value1|param2=value2]] - render the template on a
new page (as if the page contained the markup given in example 1).
There are two questions that need to be resolved to make this work:
A) How to tell the difference between example 2 and 3 if the template has no
parameters.
B) How to supply the text for the link.
If we make it compulsory to provide link text, then it would be easy to say
the last item is the link text (or the first, if you prefer). If it is not
compulsory then this becomes harder (as does knowing what to display as the
link text!) but I'm sure we can get a solution.
To fix point A, however, might require new syntax. For example
[[Template:test]] links to the template, and [[#Template:test]] links to the
rendered template (as in example 3).
- Mark Clements (HappyDog)