<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://nick-black.com/dankwiki/index.php?action=history&amp;feed=atom&amp;title=Help%3AMultiple-instance_templates</id>
	<title>Help:Multiple-instance templates - revision history</title>
	<link rel="self" type="application/atom+xml" href="https://nick-black.com/dankwiki/index.php?action=history&amp;feed=atom&amp;title=Help%3AMultiple-instance_templates"/>
	<link rel="alternate" type="text/html" href="https://nick-black.com/dankwiki/index.php?title=Help:Multiple-instance_templates&amp;action=history"/>
	<updated>2026-07-26T03:33:05Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.46.0</generator>
	<entry>
		<id>https://nick-black.com/dankwiki/index.php?title=Help:Multiple-instance_templates&amp;diff=11327&amp;oldid=prev</id>
		<title>Dank: 1 revision imported</title>
		<link rel="alternate" type="text/html" href="https://nick-black.com/dankwiki/index.php?title=Help:Multiple-instance_templates&amp;diff=11327&amp;oldid=prev"/>
		<updated>2024-11-27T03:18:40Z</updated>

		<summary type="html">&lt;p&gt;1 revision imported&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw-interface=&quot;&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 03:18, 27 November 2024&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;4&quot; class=&quot;diff-notice&quot; lang=&quot;en&quot;&gt;&lt;div class=&quot;mw-diff-empty&quot;&gt;(No difference)&lt;/div&gt;
&lt;/td&gt;&lt;/tr&gt;
&lt;!-- diff cache key wikidb:diff:1.41:old-11326:rev-11327 --&gt;
&lt;/table&gt;</summary>
		<author><name>Dank</name></author>
	</entry>
	<entry>
		<id>https://nick-black.com/dankwiki/index.php?title=Help:Multiple-instance_templates&amp;diff=11326&amp;oldid=prev</id>
		<title>MediaWiki&gt;Rand(1,2022) at 07:32, 17 May 2024</title>
		<link rel="alternate" type="text/html" href="https://nick-black.com/dankwiki/index.php?title=Help:Multiple-instance_templates&amp;diff=11326&amp;oldid=prev"/>
		<updated>2024-05-17T07:32:22Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;&amp;#039;&amp;#039;&amp;#039;Multiple-instance templates&amp;#039;&amp;#039;&amp;#039; refer to the use of a series of instances of the same [[Help:Templates|(wiki) template]] on a single wiki page, usually with unique data assigned to each instance. For instance, instances of a template may be used to list the contacts of a company, the ingredients of a recipe, the stories in a book, etc. In this way, you can present items of the same type in a uniform manner and streamline structured data so that they can be stored in the database.&lt;br /&gt;
&lt;br /&gt;
The term is typically used in the context of managing such a list of template instances by way of a form (see the form extensions below) as well as itemising data to be stored in the database (see the data storage extensions below).&lt;br /&gt;
&lt;br /&gt;
Structurally, multiple-instance templates can be either top-level templates or children of a parent template. A child template is an instance of a template assigned to a parameter of the parent template. A top-level template is not nested in this way and may or may not behave as a parent template for one or multiple child templates. Deeper levels of nesting templates are not impossible, but lack support in form extensions.&lt;br /&gt;
&lt;br /&gt;
== Example ==&lt;br /&gt;
The ingredients of some recipe for salad : &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
{{Recipe&lt;br /&gt;
|Title=My favourite salad&lt;br /&gt;
|Ingredients={{Ingredient&lt;br /&gt;
 |Item=Romaine lettuce&lt;br /&gt;
 |Quantity=Four leaves.&lt;br /&gt;
 |Preparation=Torn.&lt;br /&gt;
}}{{Ingredient&lt;br /&gt;
 |Item=Radish&lt;br /&gt;
 |Quantity=Six radishes.&lt;br /&gt;
 |Preparation=Chopped.&lt;br /&gt;
}}{{Ingredient&lt;br /&gt;
 |Item=Tomato&lt;br /&gt;
 |Quantity=2 tomatoes.&lt;br /&gt;
 |Preparation=Chopped.&lt;br /&gt;
}}{{Ingredient&lt;br /&gt;
 |Item=Licame&lt;br /&gt;
 |Quantity=A small one.&lt;br /&gt;
 |Preparation=Peeled and julienned.&lt;br /&gt;
}}&lt;br /&gt;
}}&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
(etc.)&lt;br /&gt;
&lt;br /&gt;
== Form extensions ==&lt;br /&gt;
A number of [[Help:Extensions|extensions]] are available that let you use a form to manage template instances more easily. &lt;br /&gt;
&lt;br /&gt;
* [[Extension:Page Forms]]: see especially [[Extension:Page Forms/Defining forms#Multiple-instance templates |this help page]]. The term &amp;#039;multiple-instance templates&amp;#039; was likely coined for this extension.  &lt;br /&gt;
* [[Extension:FlexForm]]: offers similar support. See especially [https://www.open-csp.org/DevOps:Doc/FlexForm/2.1/instance this help page].&lt;br /&gt;
&lt;br /&gt;
== Data storage extensions ==&lt;br /&gt;
Template instances can be used as containers for structured data. The following extensions offer parser functions that can be used in a template to store data:&lt;br /&gt;
&lt;br /&gt;
* [[Extension:Semantic MediaWiki]] (SMW) - offers the [https://www.semantic-mediawiki.org/wiki/Subobject &amp;lt;code&amp;gt;#subobject&amp;lt;/code&amp;gt; parser function] for self-contained units of property-value pairs as well as [https://www.semantic-mediawiki.org/wiki/Help:Type_Record a data type called Record].&lt;br /&gt;
* [[Extension:Cargo]] - offers &amp;lt;code&amp;gt;#cargo_declare&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;#cargo_store&amp;lt;/code&amp;gt;, which can be used in a way similar to SMW&amp;#039;s subobjects. &lt;br /&gt;
&lt;br /&gt;
== See also ==&lt;br /&gt;
* [[Help:Tabular data]]&lt;br /&gt;
* [[Manual:Managing data in MediaWiki]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Template]]&lt;/div&gt;</summary>
		<author><name>MediaWiki&gt;Rand(1,2022)</name></author>
	</entry>
</feed>