Difference between revisions of "Module:Template translation"
template --> frame[template]
>Guillom m (test unprocessed output) |
>Guillom (template --> frame[template]) |
||
Line 8: | Line 8: | ||
Otherwise, the template is rendered in its default language, without | Otherwise, the template is rendered in its default language, without | ||
modification. | modification. | ||
This is aimed at replacing Template:TNT. | This is aimed at replacing the current implementation of Template:TNT. | ||
]] | ]] | ||
Line 29: | Line 29: | ||
-- Render the template | -- Render the template | ||
return frame:expandTemplate{ title = template..langcode, args = frame.args } | return frame:expandTemplate{ title = frame[template]..langcode, args = frame.args } | ||
end | end | ||
function p.debug (frame) | function p.debug (frame) | ||
return frame:expandTemplate{ title = template, args = frame.args } | return frame:expandTemplate{ title = frame[template], args = frame.args } | ||
end | end | ||
return p | return p |