Template:Trip Report Button: Difference between revisions

From TEHCC Wiki
Jump to navigation Jump to search
(Create trip report button - form still needs defining 'Trail' for it to work)
 
m (trail to trails)
Line 10: Line 10:
Edit the page to see the template text.
Edit the page to see the template text.
</noinclude><includeonly>{{#if:{{{popup|}}}|{{#arraydefine:popup|popup}}|}}{{#if: {{CURRENTLOGGEDUSER}}
</noinclude><includeonly>{{#if:{{{popup|}}}|{{#arraydefine:popup|popup}}|}}{{#if: {{CURRENTLOGGEDUSER}}
| {{#arraydefine:pagename|{{#titleparts:{{{1}}}}}}}{{#formlink:form=Trip Report|link type=button|link text={{{2|}}}|target=Report:{{#arrayprint:pagename}}-{{CURRENTTIMESTAMP}}|query string=namespace=Report&Trip Report[Trail]={{#arrayprint:pagename}}&Trip Report[Reported By]={{CURRENTUSER}}|{{#arrayprint:popup}}|reload}}
| {{#arraydefine:pagename|{{#titleparts:{{{1}}}}}}}{{#formlink:form=Trip Report|link type=button|link text={{{2|}}}|target=Report:{{#arrayprint:pagename}}-{{CURRENTTIMESTAMP}}|query string=namespace=Report&Trip Report[Trails]={{#arrayprint:pagename}}&Trip Report[Reported By]={{CURRENTUSER}}|{{#arrayprint:popup}}|reload}}
|<br>''(log in to submit report)''}}</includeonly>
|<br>''(log in to submit report)''}}</includeonly>

Revision as of 11:38, 18 November 2018

It should be called in the following format:

{{Trip Report Button
 |Page=
 |Text=
 |popup=
}}

Edit the page to see the template text.