On Apr 19, 2005, at 8:49am, Giovanni wrote:
Is it possible to pass as argument to a template
another template? For
example I need to store in a template the url of a image and then pass
this template to another template. So when I change the image url
inside the first template automatically I change the image in all the
other templates.
I'm not exactly which case you are asking about but you can do any of
the following and there may be other possibilities (there are also
other examples at MetaWikiPedia:Help:Template):
case 1.
article = "blah", wikitext = "{{blah1}}"
template = "blah1", wikitext = "blah {{blah2}}"
template = "blah2", wikitext = "blah blah"
article blah displays text: "blah blah blah"
case 2.
article = "blah", wikitext = "{{blah1|blah2}}
template = "blah1", wikitext = "blah {{{{{1}}}}}
template = "blah2", wikitext = "blah blah"
article blah displays text: "blah blah blah"
case 3.
article = "blah", wikitext = "blah {{blah1|blah|blah2}}"
template = "blah1", wikitext = "{{{1}}} {{{{{2}}}|{{{1}}}}}"
template = "blah2", wikitext = "{{{1}}}"
article blah displays text: "blah blah blah"
I'm not sure how deep you can nest templates but it seems you can go at
least 3-4 deep.
John Blumel