Hi,
How can I create a template like: <some-tag attr="{{{1}}}"> ... </some-tag>
?
thanks, ittay
2007/2/5, Ittay Dror ittayd@qlusters.com:
Hi,
How can I create a template like:
<some-tag attr="{{{1}}}"> ... </some-tag>
User a parser function.
See http://www.gossamer-threads.com/lists/wiki/mediawiki/77335
Fernando Correia wrote:
2007/2/5, Ittay Dror ittayd@qlusters.com:
Hi,
How can I create a template like:
<some-tag attr="{{{1}}}"> ... </some-tag>
User a parser function.
See http://www.gossamer-threads.com/lists/wiki/mediawiki/77335
thanks! can you by any chance submit your parser function and en example usage? (is it something like {{#tag: some-tag | attr="{{{1}}}" | ...}}?)
MediaWiki-l mailing list MediaWiki-l@lists.wikimedia.org http://lists.wikimedia.org/mailman/listinfo/mediawiki-l
Ittay Dror wrote:
Fernando Correia wrote:
2007/2/5, Ittay Dror ittayd@qlusters.com:
Hi,
How can I create a template like:
<some-tag attr="{{{1}}}"> ... </some-tag>
User a parser function.
See http://www.gossamer-threads.com/lists/wiki/mediawiki/77335
thanks! can you by any chance submit your parser function and en example usage? (is it something like {{#tag: some-tag | attr="{{{1}}}" | ...}}?)
ok, worked it out myself. this is the parser function: (tag is the first argument, body is last)
function qwfProcessExtTag(&$parser) { $args = func_get_args(); array_shift( $args );
$tag = trim(array_shift($args)); $body = array_pop($args); return "<" . $tag . ' ' . implode(' ', $args) . '>' . $body . '</' . $tag . '>'; }
MediaWiki-l mailing list MediaWiki-l@lists.wikimedia.org http://lists.wikimedia.org/mailman/listinfo/mediawiki-l
2007/2/6, Ittay Dror ittayd@qlusters.com:
thanks! can you by any chance submit your parser function and en example usage? (is it something like {{#tag: some-tag | attr="{{{1}}}" | ...}}?)
Sure.
mediawiki-l@lists.wikimedia.org