Template:Example: Difference between revisions
Content deleted Content added
imported>FrozenPlum m Add a flag for no sandbox |
imported>FrozenPlum mNo edit summary |
||
(9 intermediate revisions by 3 users not shown) | |||
Line 1:
<templatestyles src="Example/style.css" /><!--
--><includeonly><div class="demo-inputbox-wrapper">
{{#if:{{{nosandbox|}}}|<!-- has value don't display --><!-- otherwise display
-->|<div class="demo-viewpage" style="margin-top:{{{margin|}}};">
[{{fullurl:Special:Mypage/Sandbox|action=edit}}§ion=new&preloadtitle={{urlencode:{{{1}}}}}&preload={{#if:{{{base|}}}|{{anchorencode:{{{base}}}}}|{{urlencode:{{FULLPAGENAME}}}}}}/{{#if:{{{noparam|}}}|<!-- not empty -->|Parameter:_}}{{{1|}}}_(example{{#if:{{{eg|}}}|_{{{eg|}}}|_1}}) {{{2|Test in sandbox}}}]
</div>}}
{{#if:{{{noresult|}}}|<!-- has value don't display --><!-- otherwise display
-->|<div class="demo-viewpage" style="margin-top:{{{margin|}}};">
[[{{#if:{{{base|}}}|{{
</div>
</div></includeonly><noinclude>
==Tests==
<ol>▼
<li value="2"><code><nowiki>{{example|category|base=Criteria for page selection|eg=2|nosandbox=y}}</nowiki></code> gives: {{example|category|base=
▲<ol>
▲<li value="2"><code><nowiki>{{example|category|base=Criteria for page selection|nosandbox=y}}</nowiki></code> gives: {{example|category|base=Criteria_for_page_selection|eg=2|nosandbox=y}}</li>
<li value="3"><code><nowiki>{{example|category|base=Criteria for page selection|eg=2|noresult=y}}</nowiki></code> gives: {{example|category|base=
<li value="4"><code><nowiki>{{example|category|base=Criteria for page selection|Link Text|eg=2|noresult=y|margin=.5em}}</nowiki></code> gives: {{example|category|base=Criteria for page selection|Link Text|eg=2|noresult=y|margin=.5em}}</li>
</ol>
<!--
* Plain URL exampe (needed for later conversion, wanting to convert override for both):
** [{{fullurl:Special:Mypage/Sandbox|action=edit}}§ion=new&preloadtitle=New_Header&preload=Criteria_for_page_selection/Parameter:_category_(example_1) Test in sandbox]
* {{urlencode:{{FULLPAGENAME}}}}
* {{PAGENAMEE}} -->
|