Array

Template:Test4: Difference between revisions

mNo edit summary
mNo edit summary
Line 1: Line 1:
<TABLE border="0"><CAPTION></CAPTION><TR valign="top"><TD valign="top"; style="width:15%"><font size=3; color="bf009a">'''{{#if:{{{title|}}}|{{#switch: {{{title|}}}|main=Main&nbsp;article{{#if:{{{subject2|}}}|s|}}|Main=Main&nbsp;article{{#if:{{{subject2|}}}|s|}}|SeeAlso=See&nbsp;also:|seealso=See&nbsp;also:|detail=For&nbsp;more&nbsp;details|details=For&nbsp;more&nbsp;details|Detail=For&nbsp;more&nbsp;details|Details=For&nbsp;more&nbsp;details|{{{title}}}}}|Related&nbsp;article{{#if:{{{subject2|}}}|s|}}}}:'''</font><TD><font size=3>'''{{#if:{{{subject|}}}|[[{{{link}}}|{{{subject}}}]]'''</font>{{#if:{{{summary|}}}|<br>'''Summary:'''&nbsp;{{{summary}}}|}}|[[{{{link1}}}|{{{subject1}}}]]'''</font>{{#if:{{{summary1|}}}|<br>'''Summary:'''&nbsp;{{{summary1}}}|}}}}{{#if:{{{link6|}}}|<TD><font size=3>'''[[{{{link6}}}|{{{subject6}}}]]'''</font>{{#if:{{{summary6|}}}|<br>'''Summary:'''&nbsp;{{{summary6}}}|}}|<!--nil-->}}{{#if:{{{link2|}}}|<TR valign="top"><TD><TD><font size=3>'''[[{{{link2}}}|{{{subject2}}}]]'''</font>{{#if:{{{summary2|}}}|<br>'''Summary:'''&nbsp;{{{summary2}}}|}}|<!--nil-->}}{{#if:{{{link7|}}}|<TD><font size=3>'''[[{{{link7}}}|{{{subject7}}}]]'''</font>{{#if:{{{summary7|}}}|<br>'''Summary:'''&nbsp;{{{summary7}}}|}}|<!--nil-->}}{{#if:{{{link3|}}}|<TR valign="top"><TD><TD><font size=3>'''[[{{{link3}}}|{{{subject3}}}]]'''</font>{{#if:{{{summary3|}}}|<br>'''Summary:'''&nbsp;{{{summary3}}}|}}|<!--nil-->}}{{#if:{{{link8|}}}|<TD><font size=3>'''[[{{{link8}}}|{{{subject8}}}]]'''</font>{{#if:{{{summary8|}}}|<br>'''Summary:'''&nbsp;{{{summary8}}}|}}|<!--nil-->}}{{#if:{{{link4|}}}|<TR valign="top"><TD><TD><font size=3>'''[[{{{link4}}}|{{{subject4}}}]]'''</font>{{#if:{{{summary4|}}}|<br>'''Summary:'''&nbsp;{{{summary4}}}|}}|<!--nil-->}}{{#if:{{{link9|}}}|<TD><font size=3>'''[[{{{link9}}}|{{{subject9}}}]]'''</font>{{#if:{{{summary9|}}}|<br>'''Summary:'''&nbsp;{{{summary9}}}|}}|<!--nil-->}}{{#if:{{{link5|}}}|<TR valign="top"><TD><TD><font size=3>'''[[{{{link5}}}|{{{subject5}}}]]'''</font>{{#if:{{{summary5|}}}|<br>'''Summary:'''&nbsp;{{{summary5}}}|}}|<!--nil-->}}{{#if:{{{link10|}}}|<TD><font size=3>'''[[{{{link10}}}|{{{subject10}}}]]'''</font>{{#if:{{{summary10|}}}|<br>'''Summary:'''&nbsp;{{{summary10}}}|}}|<!--nil-->}}</TABLE>
<TABLE border="0"><CAPTION></CAPTION><TR valign="top"><TD valign="top"; style="width:15%"><font size=3; color="bf009a">'''{{#if:{{{title|}}}|{{#switch: {{{title|}}}|main=Main&nbsp;article{{#if:{{{subject2|}}}|s|}}|Main=Main&nbsp;article{{#if:{{{subject2|}}}|s|}}|SeeAlso=See&nbsp;also|seealso=See&nbsp;also|detail=For&nbsp;more&nbsp;details|details=For&nbsp;more&nbsp;details|Detail=For&nbsp;more&nbsp;details|Details=For&nbsp;more&nbsp;details|{{{title}}}}}|Related&nbsp;article{{#if:{{{subject2|}}}|s|}}}}:'''</font><TD><font size=3>'''{{#if:{{{subject|}}}|[[{{{link}}}|{{{subject}}}]]'''</font>{{#if:{{{summary|}}}|<br>'''Summary:'''&nbsp;{{{summary}}}|}}|[[{{{link1}}}|{{{subject1}}}]]'''</font>{{#if:{{{summary1|}}}|<br>'''Summary:'''&nbsp;{{{summary1}}}|}}}}{{#if:{{{link6|}}}|<TD><font size=3>'''[[{{{link6}}}|{{{subject6}}}]]'''</font>{{#if:{{{summary6|}}}|<br>'''Summary:'''&nbsp;{{{summary6}}}|}}|<!--nil-->}}{{#if:{{{link2|}}}|<TR valign="top"><TD><TD><font size=3>'''[[{{{link2}}}|{{{subject2}}}]]'''</font>{{#if:{{{summary2|}}}|<br>'''Summary:'''&nbsp;{{{summary2}}}|}}|<!--nil-->}}{{#if:{{{link7|}}}|<TD><font size=3>'''[[{{{link7}}}|{{{subject7}}}]]'''</font>{{#if:{{{summary7|}}}|<br>'''Summary:'''&nbsp;{{{summary7}}}|}}|<!--nil-->}}{{#if:{{{link3|}}}|<TR valign="top"><TD><TD><font size=3>'''[[{{{link3}}}|{{{subject3}}}]]'''</font>{{#if:{{{summary3|}}}|<br>'''Summary:'''&nbsp;{{{summary3}}}|}}|<!--nil-->}}{{#if:{{{link8|}}}|<TD><font size=3>'''[[{{{link8}}}|{{{subject8}}}]]'''</font>{{#if:{{{summary8|}}}|<br>'''Summary:'''&nbsp;{{{summary8}}}|}}|<!--nil-->}}{{#if:{{{link4|}}}|<TR valign="top"><TD><TD><font size=3>'''[[{{{link4}}}|{{{subject4}}}]]'''</font>{{#if:{{{summary4|}}}|<br>'''Summary:'''&nbsp;{{{summary4}}}|}}|<!--nil-->}}{{#if:{{{link9|}}}|<TD><font size=3>'''[[{{{link9}}}|{{{subject9}}}]]'''</font>{{#if:{{{summary9|}}}|<br>'''Summary:'''&nbsp;{{{summary9}}}|}}|<!--nil-->}}{{#if:{{{link5|}}}|<TR valign="top"><TD><TD><font size=3>'''[[{{{link5}}}|{{{subject5}}}]]'''</font>{{#if:{{{summary5|}}}|<br>'''Summary:'''&nbsp;{{{summary5}}}|}}|<!--nil-->}}{{#if:{{{link10|}}}|<TD><font size=3>'''[[{{{link10}}}|{{{subject10}}}]]'''</font>{{#if:{{{summary10|}}}|<br>'''Summary:'''&nbsp;{{{summary10}}}|}}|<!--nil-->}}</TABLE><!-----
 
HOW TO USE THIS TEMPLATE:
 
{{Related articles
|title=
 
|link1=
|subject1=
|summary1=
 
|link2=
|subject2=
|summary2=
 
|link3= etc.
|subject3=
|summary3=
}}
 
 
|link1 --> the name of the wiki page
|subject1 --> the text that will appear to the user for above link
|summary1= --> Short summary text. If empty, nothing is shown
 
title --> If blank, uses "Related articles". If main, detail, seealso, uses those as title. Otherwise, includes what's in title. If you want an "s" to appear automatically for plural, include this in the title:
 
{{#if:{{{subject2|}}}|s|}}
 
So, title=Article{{#if:{{{subject2|}}}|s|}}: will produce:
 
Article: if there is only one set of link, subject or
Articles: if more than one.
 
If there are spaces in the title, it looks better if you use a "non breaking space" because then the title will stay on one line and not be wrapped. Instead of "The Title" put "The&nbsp;Title"-->

Revision as of 21:32, 1 June 2024

Related article:[[{{{link1}}}|{{{subject1}}}]]

the name of the wiki page

|subject1 --> the text that will appear to the user for above link |summary1= --> Short summary text. If empty, nothing is shown

title --> If blank, uses "Related articles". If main, detail, seealso, uses those as title. Otherwise, includes what's in title. If you want an "s" to appear automatically for plural, include this in the title:


So, title=Article: will produce:

Article: if there is only one set of link, subject or Articles: if more than one.

If there are spaces in the title, it looks better if you use a "non breaking space" because then the title will stay on one line and not be wrapped. Instead of "The Title" put "The Title"-->