How to Create an Infobox: Difference between revisions

m
Line 252: Line 252:
*Notice that there are <font color="red">{{ }}</font color> at each end of the expression.   
*Notice that there are <font color="red">{{ }}</font color> at each end of the expression.   
*After the first set of <font color="red">{{</font color> notice <font color="red">#if:</font color> which consists of a pound sign <font color="red">#</font color>, the word <font color="red">if</font color> and a colon <font color="red">:</font color>.
*After the first set of <font color="red">{{</font color> notice <font color="red">#if:</font color> which consists of a pound sign <font color="red">#</font color>, the word <font color="red">if</font color> and a colon <font color="red">:</font color>.
*After the colon you see the parameter repeated with the addition of a pipe after the word inside the {{{}}} and a pipe on the outside like so:<font color="red"><nowiki>{{{parameter|}}}|</nowiki></font color>.  We will not take the time to explain what all this code means but if you are interested see the footnote<ref>The coding looks complicated but it is really not.  First this is an “if” statement.  In essence, it says “if” you have A do B or if you do not, do C.  Or another way to put it, if you have peanut butter, make a sandwich otherwise starve.   
*After the colon you see the parameter repeated with the addition of a pipe after the word inside the <font color="red">{{{}}}<font color> and a pipe on the outside like so:<font color="red"><nowiki>{{{parameter|}}}|</nowiki></font color>.  We will not take the time to explain what all this code means but if you are interested see the footnote<ref>The coding looks complicated but it is really not.  First this is an “if” statement.  In essence, it says “if” you have A do B or if you do not, do C.  Or another way to put it, if you have peanut butter, make a sandwich otherwise starve.   
*The coding looks like so:
*The coding looks like so:
<nowiki>{{#if: peanut butter|make sandwich|starve}} </nowiki>
<nowiki>{{#if: peanut butter|make sandwich|starve}} </nowiki>
Interface administrators, smwadministrator, smwcurator, smweditor
82,369

edits