<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>http://70.231.62.181/index.php?action=history&amp;feed=atom&amp;title=Module%3AAuthority_control%2Fconfig%2Fdoc</id>
	<title>Module:Authority control/config/doc - Revision history</title>
	<link rel="self" type="application/atom+xml" href="http://70.231.62.181/index.php?action=history&amp;feed=atom&amp;title=Module%3AAuthority_control%2Fconfig%2Fdoc"/>
	<link rel="alternate" type="text/html" href="http://70.231.62.181/index.php?title=Module:Authority_control/config/doc&amp;action=history"/>
	<updated>2026-04-22T18:08:00Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.45.1</generator>
	<entry>
		<id>http://70.231.62.181/index.php?title=Module:Authority_control/config/doc&amp;diff=15143318&amp;oldid=prev</id>
		<title>imported&gt;Christian75: {{high use}}</title>
		<link rel="alternate" type="text/html" href="http://70.231.62.181/index.php?title=Module:Authority_control/config/doc&amp;diff=15143318&amp;oldid=prev"/>
		<updated>2024-12-29T02:31:41Z</updated>

		<summary type="html">&lt;p&gt;{{high use}}&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;{{high use}}&lt;br /&gt;
{{Authority control/related}}&lt;br /&gt;
{{#ifeq:{{SUBPAGENAME}}|doc||{{ombox&lt;br /&gt;
|text=Difference with: {{#ifeq:{{PAGENAME}}|Authority control/config/sandbox||{{Compare pages|{{FULLPAGENAME}}|Module:Authority control/config/sandbox|sandbox}}}} {{#ifeq:{{PAGENAME}}|Authority control/config/staging||{{Compare pages|{{FULLPAGENAME}}|Module:Authority control/config/staging|staging}}}} {{#ifeq:{{PAGENAME}}|Authority control/config||{{Compare pages|{{FULLPAGENAME}}|Module:Authority control/config|live}}}}&lt;br /&gt;
}}}}&lt;br /&gt;
Contains configuation details for [[Module:Authority control]].&lt;br /&gt;
{{PAGENAME}}&lt;br /&gt;
=== Syntax ===&lt;br /&gt;
The syntax for the &amp;lt;code&amp;gt;p.config&amp;lt;/code&amp;gt; table is as follows:&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;property =&amp;#039;&amp;#039;&amp;#039; Wikidata property number, without the prefix P.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;section =&amp;#039;&amp;#039;&amp;#039; section number to place the identifier. See [[#List of sections]] for details.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;pattern =&amp;#039;&amp;#039;&amp;#039; [[mw:Extension:Scribunto/Lua reference manual#Patterns|Lua pattern]] of valid format for identifier. Note this is similar but not identical to a [[regular expression]]. If this is omitted, then the module will not check the validity of the identifiers.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;link =&amp;#039;&amp;#039;&amp;#039; the URL of the external page with details of the identifier. The code &amp;lt;code&amp;gt;$1&amp;lt;/code&amp;gt; will be replaced with the identifier.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;label =&amp;#039;&amp;#039;&amp;#039; the label for the link.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;remark =&amp;#039;&amp;#039;&amp;#039; a brief explanation of the authority control database, for use on the documentation of [[Template:Authority control]] only.&lt;br /&gt;
&lt;br /&gt;
=== Example ===&lt;br /&gt;
The syntax below generates a link to the [[Dictionary of Irish Biography]] in section 5. It gets its data from Wikidata property {{Q|P6829}} and identifiers need to be in the following form: 0, followed by 0 or 1, followed by 4 digits, possibly followed by a decimal point and then a letter from A to D.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;Lua&amp;quot;&amp;gt;{&lt;br /&gt;
  property = 6829,&lt;br /&gt;
  section = 5,&lt;br /&gt;
  pattern = &amp;#039;0[01]%d%d%d%d%.?[A-D]?&amp;#039;,&lt;br /&gt;
  link = &amp;#039;https://doi.org/10.3318/dib.$1.v1&amp;#039;,&lt;br /&gt;
  label = &amp;#039;Ireland&amp;#039;,&lt;br /&gt;
},&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Advanced parameters ===&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;patterns =&amp;#039;&amp;#039;&amp;#039; if more than one Lua pattern is needed, then use the plural form of this argument and include the comma-separated list of patterns enclosed by curly braces.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;prefix =&amp;#039;&amp;#039;&amp;#039; a prefix to be included before the links. In this case numbers 1, 2, ... will be used as the labels and the &amp;#039;&amp;#039;&amp;#039;label&amp;#039;&amp;#039;&amp;#039; field will be ignored.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;valid =&amp;#039;&amp;#039;&amp;#039; the name of a custom Lua function in [[Module:Authority control/auxiliary|/auxiliary]] used to determine if the identifier is valid or not, in case the &amp;#039;&amp;#039;&amp;#039;pattern&amp;#039;&amp;#039;&amp;#039; method cannot be used. It should return &amp;lt;code&amp;gt;false&amp;lt;/code&amp;gt; if the identifier is invalid.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;customlink =&amp;#039;&amp;#039;&amp;#039; the name of a custom Lua function in [[Module:Authority control/auxiliary|/auxiliary]] which will produce the entire external link. It should return &amp;lt;code&amp;gt;false&amp;lt;/code&amp;gt; if the identifier is invalid.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;suppressedbyproperty =&amp;#039;&amp;#039;&amp;#039; if this identifier should not be displayed if other identifiers are present, then specify them here in a comma-separated list enclosed by curley braces. Note: the property to be suppressed must be listed later in the list than the property which suppresses it.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;category =&amp;#039;&amp;#039;&amp;#039; defines a category that should be used to track uses of this property (not usually needed). For example if &amp;lt;code&amp;gt;category = &amp;#039;VIAF&amp;#039;&amp;lt;/code&amp;gt; then [[:Category:Articles with VIAF identifiers]] and [[:Category:Articles with faulty VIAF identifiers]] will be populated.&lt;br /&gt;
&lt;br /&gt;
=== List of sections ===&lt;br /&gt;
The names of each section are defined by the &amp;lt;code&amp;gt;p.sectionNames&amp;lt;/code&amp;gt; function. The syntax is as follows:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;&amp;#039;&amp;#039;&amp;#039;[number]&amp;#039;&amp;#039;&amp;#039; = {name = &amp;#039;&amp;#039;&amp;#039;name of section&amp;#039;&amp;#039;&amp;#039;, hidelabelwhenalone = &amp;#039;&amp;#039;&amp;#039;true/false&amp;#039;&amp;#039;&amp;#039;},&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
where&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;number&amp;#039;&amp;#039;&amp;#039; is the section number (must be sequential integer).&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;name of section&amp;#039;&amp;#039;&amp;#039; is the name which appears in the header column of the infobox.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;true/false&amp;#039;&amp;#039;&amp;#039; is set to true if you want the name to be suppressed when this section is the only section to be displayed. (For example, there is no point in showing &amp;quot;Other&amp;quot; if that is the only section.) The default is false.&lt;br /&gt;
&lt;br /&gt;
For example, the section 7 is defined as:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;[7] = {name = &amp;#039;Other&amp;#039;, hidelabelwhenalone = true}&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This section has name &amp;quot;Other&amp;quot; and it will be hidden when it is the only section to be shown.&lt;br /&gt;
&lt;br /&gt;
The current list of sections is shown below:&lt;br /&gt;
{{#invoke:Authority control/documentation{{#ifeq:{{SUBPAGENAME}}|sandbox|/sandbox}}|sectiontable|config={{#ifeq:{{SUBPAGENAME}}|sandbox|sandbox}}}}&lt;br /&gt;
&lt;br /&gt;
=== Whitelists ===&lt;br /&gt;
The whitelists are defined by the &amp;lt;code&amp;gt;p.whitelists&amp;lt;/code&amp;gt; function. The syntax is as follows:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;&amp;#039;&amp;#039;&amp;#039;code&amp;#039;&amp;#039;&amp;#039; = {topic = &amp;#039;&amp;#039;&amp;#039;topic QID&amp;#039;&amp;#039;&amp;#039;, properties = {&amp;#039;&amp;#039;&amp;#039;property PIDs&amp;#039;&amp;#039;&amp;#039;}}&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
where&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;code&amp;#039;&amp;#039;&amp;#039; is the code of the whitelist which is called via the {{para|show}} parameter.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;topic QID&amp;#039;&amp;#039;&amp;#039; is the Wikidata QID for the topic represented by the whitelist, without the Q prefix.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;property QIDs&amp;#039;&amp;#039;&amp;#039; is a comma-separated list of PIDs for the properties included in the whitelist (without the prefix P).&lt;br /&gt;
&lt;br /&gt;
For example, the whitelist for Italy is defined as:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;it = {topic = 38, properties = {396, 3863, 1986, 8034}},&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The whitelist has code &amp;lt;code&amp;gt;it&amp;lt;/code&amp;gt;, represents {{Q|Q38}} and includes the following properties: {{Q|P396}}, {{Q|P3863}}, {{Q|P1986}}, {{Q|P8034}}.&lt;br /&gt;
&lt;br /&gt;
The currently recognised whitelists are listed below:&lt;br /&gt;
{{#invoke:Authority control/documentation{{#ifeq:{{SUBPAGENAME}}|sandbox|/sandbox}}|whitelisttable|config={{#ifeq:{{SUBPAGENAME}}|sandbox|sandbox}}}}&lt;br /&gt;
&lt;br /&gt;
=== See also ===&lt;br /&gt;
* [[Module:Authority control/auxiliary]]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;includeonly&amp;gt;{{#switch:{{SUBPAGENAME}}&lt;br /&gt;
|sandbox|staging=&amp;lt;!--Suppress categories--&amp;gt;&lt;br /&gt;
|#default=[[Category:Wikipedia authority control]]&lt;br /&gt;
}}&amp;lt;/includeonly&amp;gt;&lt;br /&gt;
&amp;lt;noinclude&amp;gt;&lt;br /&gt;
[[Category:Module documentation pages]]&lt;br /&gt;
&amp;lt;/noinclude&amp;gt;&lt;/div&gt;</summary>
		<author><name>imported&gt;Christian75</name></author>
	</entry>
</feed>