Difference between revisions of "User:Philmasterplus/TemplateSandbox"

From Kolmafia
Jump to navigation Jump to search
(Replaced content with "This page has been incorporated into Template:Data. Nothing to see here.")
Tag: Replaced
Line 1: Line 1:
<includeonly>{{{1|{{{error|Missing parameter '1' for Template:Data}}}}}}{{{2|{{{error|Missing parameter 'field' for Template:Data}}}}}}
+
This page has been incorporated into [[Template:Data]]. Nothing to see here.
{{#ifexist:{{{1}}}
 
|{{
 
  {{{1}}}
 
  |format=#switch:{{{2}}}
 
  |{{{3}}}
 
}}
 
|{{{error|Page '{{{1}}}' does not exist in Template:Data}}}
 
}}</includeonly>
 
<noinclude>
 
<templatedata>
 
{
 
  "description": "Utility template that extracts a field from a specially formatted page.",
 
  "params": {
 
    "1": {
 
      "label": "Page name",
 
      "description": "Name of the source page to extract the data from. The source page is evaluated as a #switch-statement.",
 
      "type": "wiki-page-name",
 
      "required": true,
 
      "example": "visit_url"
 
    },
 
    "2": {
 
      "label": "Field name",
 
      "description": "Field name to extract from the source page.",
 
      "type": "line",
 
      "required": true,
 
      "example": "function1.parameter1"
 
    },
 
    "3": {
 
      "label": "Default value",
 
      "description": "Default value if the page does not contain the given field",
 
      "type": "string",
 
      "example": "no_name"
 
    }
 
  }
 
}
 
</templatedata>
 
 
 
This template is similar to [https://kol.coldfront.net/thekolwiki/index.php/Template:Data Template:Data] in the KoL Coldfront Wiki.
 
</noinclude>
 

Revision as of 21:11, 18 December 2020

This page has been incorporated into Template:Data. Nothing to see here.