Right template

    Keywords: SL description

<template>=>{{{1}}}</template>

See also: Left Template

Purpose

Herman: I made this template because there is no way to check for the value of template parameters.

On the picture template, if you want to have a caption (or author/license), then you want it under the image. But that requires knowing where the image is (ie, the value of the "align" parameter), which is impossible. So I created this, which allowed me to do:

{{{{{align}}}|{{{caption}}}}}

Which aligns the caption the right way, because {{{align}}} is replaced with (for example) "right", and {{{caption}}} with the caption text, so the above results in:

{{right|caption text}}

Which then inlines this template, and does what I want.

I don't know a better way to do this right now, if anyone has a solution that is less ugly, please let me know.


Right template last edited by HermanHiddema on November 17, 2009 - 16:04
RecentChanges · StartingPoints · About
Edit page ·Search · Related · Page info · Latest diff
[Welcome to Sensei's Library!]
RecentChanges
StartingPoints
About
RandomPage
Search position
Page history
Latest page diff
Partner sites:
Go Teaching Ladder
Goproblems.com
Login / Prefs
Tools
Sensei's Library