<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://alpha.wikianesthesia.org/w/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=WikiAnesthesia</id>
	<title>WikiAnesthesia - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://alpha.wikianesthesia.org/w/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=WikiAnesthesia"/>
	<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/wiki/Special:Contributions/WikiAnesthesia"/>
	<updated>2026-04-29T22:36:02Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.37.1</generator>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Propofol&amp;diff=4642</id>
		<title>Propofol</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Propofol&amp;diff=4642"/>
		<updated>2022-03-17T10:51:59Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox drug reference&lt;br /&gt;
| trade_names = Diprivan&lt;br /&gt;
| image_file = Propofol.png&lt;br /&gt;
| image_caption = &lt;br /&gt;
| drug_class = Sedative hypnotic&lt;br /&gt;
| drug_class_color = sedative_hypnotic&lt;br /&gt;
| uses = Induction and maintenance of anesthesia, sedation&lt;br /&gt;
| contraindications = Egg/soy allergy (controversial)&lt;br /&gt;
| routes = Intravenous&lt;br /&gt;
| dosage = Induction of anesthesia:&lt;br /&gt;
* Adult: 1-2.5 mg/kg&lt;br /&gt;
* Elderly: 1-1.5 mg/kg&lt;br /&gt;
* Pediatric: 2.5-3.5 mg/kg&lt;br /&gt;
Maintenance of anesthesia:&lt;br /&gt;
* Adult: 100-200 mcg/kg/min&lt;br /&gt;
* Elderly: 50-100 mcg/kg/min&lt;br /&gt;
* Pediatric: 125-300 mcg/kg/min&lt;br /&gt;
| mechanism = GABA agonism&lt;br /&gt;
| adverse_effects = Hypotension&lt;br /&gt;
Bradycardia&lt;br /&gt;
Pain on injection&lt;br /&gt;
| time_onset = 15-30 seconds&lt;br /&gt;
| duration = 5-10 minutes&lt;br /&gt;
| metabolism = Liver glucuronidation&lt;br /&gt;
| halflife_redistribution = 2-8 minutes (initial)&lt;br /&gt;
30-70 minutes (slow)&lt;br /&gt;
| halflife_elimination = 1.5-31 hours&lt;br /&gt;
| clearance = 1.5-2.2 L/min&lt;br /&gt;
| protein_binding = 95-99%&lt;br /&gt;
| pka = 11&lt;br /&gt;
| volume_distribution = 6-40 L (central)&lt;br /&gt;
150-700 L (steady state)&lt;br /&gt;
| formula = C&amp;lt;sub&amp;gt;12&amp;lt;/sub&amp;gt;H&amp;lt;sub&amp;gt;18&amp;lt;/sub&amp;gt;O&lt;br /&gt;
| molar_mass = 178.275 g/mol&lt;br /&gt;
}}Provide a brief summary of this drug here. Test. Another test. Yet another test. Wooooooooo&lt;br /&gt;
&lt;br /&gt;
==Uses&amp;lt;!-- Describe uses of the drug. If appropriate, add subsections for each indication. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
==Contraindications&amp;lt;!-- List contraindications and precautions for use of the drug. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
===Absolute contraindications&amp;lt;!-- List absolute contraindications for use of the drug. If none, this section may be removed. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
===Precautions&amp;lt;!-- List precautions for use of the drug. If none, this section may be removed. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
==Pharmacology==&lt;br /&gt;
&lt;br /&gt;
===Pharmacodynamics&amp;lt;!-- Describe the effects of the drug on the body. If appropriate, add subsections by organ system --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
====Mechanism of action&amp;lt;!-- Describe the mechanism of action for the primary uses of the drug. --&amp;gt;====&lt;br /&gt;
&lt;br /&gt;
====Adverse effects&amp;lt;!-- Describe any potential adverse effects of the drug. --&amp;gt;====&lt;br /&gt;
[[File:Hilton Worldwide logo.svg|thumb]]&lt;br /&gt;
&lt;br /&gt;
===Pharmacokinetics&amp;lt;!-- Describe the pharmacokinetics of the drug. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
==Chemistry and formulation&amp;lt;!-- Describe the chemistry and formulation of the drug. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
==History&amp;lt;!-- Describe the historical development of the drug. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
==References==&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Propofol&amp;diff=4641</id>
		<title>Propofol</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Propofol&amp;diff=4641"/>
		<updated>2022-03-17T10:43:55Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox drug reference&lt;br /&gt;
| trade_names = Diprivan&lt;br /&gt;
| image_file = Propofol.png&lt;br /&gt;
| image_caption = &lt;br /&gt;
| drug_class = Sedative hypnotic&lt;br /&gt;
| drug_class_color = sedative_hypnotic&lt;br /&gt;
| uses = Induction and maintenance of anesthesia, sedation&lt;br /&gt;
| contraindications = Egg/soy allergy (controversial)&lt;br /&gt;
| routes = Intravenous&lt;br /&gt;
| dosage = Induction of anesthesia:&lt;br /&gt;
* Adult: 1-2.5 mg/kg&lt;br /&gt;
* Elderly: 1-1.5 mg/kg&lt;br /&gt;
* Pediatric: 2.5-3.5 mg/kg&lt;br /&gt;
Maintenance of anesthesia:&lt;br /&gt;
* Adult: 100-200 mcg/kg/min&lt;br /&gt;
* Elderly: 50-100 mcg/kg/min&lt;br /&gt;
* Pediatric: 125-300 mcg/kg/min&lt;br /&gt;
| mechanism = GABA agonism&lt;br /&gt;
| adverse_effects = Hypotension&lt;br /&gt;
Bradycardia&lt;br /&gt;
Pain on injection&lt;br /&gt;
| time_onset = 15-30 seconds&lt;br /&gt;
| duration = 5-10 minutes&lt;br /&gt;
| metabolism = Liver glucuronidation&lt;br /&gt;
| halflife_redistribution = 2-8 minutes (initial)&lt;br /&gt;
30-70 minutes (slow)&lt;br /&gt;
| halflife_elimination = 1.5-31 hours&lt;br /&gt;
| clearance = 1.5-2.2 L/min&lt;br /&gt;
| protein_binding = 95-99%&lt;br /&gt;
| pka = 11&lt;br /&gt;
| volume_distribution = 6-40 L (central)&lt;br /&gt;
150-700 L (steady state)&lt;br /&gt;
| formula = C&amp;lt;sub&amp;gt;12&amp;lt;/sub&amp;gt;H&amp;lt;sub&amp;gt;18&amp;lt;/sub&amp;gt;O&lt;br /&gt;
| molar_mass = 178.275 g/mol&lt;br /&gt;
}}Provide a brief summary of this drug here. Test. Another test. Yet another test. Woooooooo&lt;br /&gt;
&lt;br /&gt;
==Uses&amp;lt;!-- Describe uses of the drug. If appropriate, add subsections for each indication. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
==Contraindications&amp;lt;!-- List contraindications and precautions for use of the drug. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
===Absolute contraindications&amp;lt;!-- List absolute contraindications for use of the drug. If none, this section may be removed. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
===Precautions&amp;lt;!-- List precautions for use of the drug. If none, this section may be removed. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
==Pharmacology==&lt;br /&gt;
&lt;br /&gt;
===Pharmacodynamics&amp;lt;!-- Describe the effects of the drug on the body. If appropriate, add subsections by organ system --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
====Mechanism of action&amp;lt;!-- Describe the mechanism of action for the primary uses of the drug. --&amp;gt;====&lt;br /&gt;
&lt;br /&gt;
====Adverse effects&amp;lt;!-- Describe any potential adverse effects of the drug. --&amp;gt;====&lt;br /&gt;
[[File:Hilton Worldwide logo.svg|thumb]]&lt;br /&gt;
&lt;br /&gt;
===Pharmacokinetics&amp;lt;!-- Describe the pharmacokinetics of the drug. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
==Chemistry and formulation&amp;lt;!-- Describe the chemistry and formulation of the drug. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
==History&amp;lt;!-- Describe the historical development of the drug. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
==References==&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Propofol&amp;diff=4640</id>
		<title>Propofol</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Propofol&amp;diff=4640"/>
		<updated>2022-03-17T10:14:39Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox drug reference&lt;br /&gt;
| trade_names = Diprivan&lt;br /&gt;
| image_file = Propofol.png&lt;br /&gt;
| image_caption = &lt;br /&gt;
| drug_class = Sedative hypnotic&lt;br /&gt;
| drug_class_color = sedative_hypnotic&lt;br /&gt;
| uses = Induction and maintenance of anesthesia, sedation&lt;br /&gt;
| contraindications = Egg/soy allergy (controversial)&lt;br /&gt;
| routes = Intravenous&lt;br /&gt;
| dosage = Induction of anesthesia:&lt;br /&gt;
* Adult: 1-2.5 mg/kg&lt;br /&gt;
* Elderly: 1-1.5 mg/kg&lt;br /&gt;
* Pediatric: 2.5-3.5 mg/kg&lt;br /&gt;
Maintenance of anesthesia:&lt;br /&gt;
* Adult: 100-200 mcg/kg/min&lt;br /&gt;
* Elderly: 50-100 mcg/kg/min&lt;br /&gt;
* Pediatric: 125-300 mcg/kg/min&lt;br /&gt;
| mechanism = GABA agonism&lt;br /&gt;
| adverse_effects = Hypotension&lt;br /&gt;
Bradycardia&lt;br /&gt;
Pain on injection&lt;br /&gt;
| time_onset = 15-30 seconds&lt;br /&gt;
| duration = 5-10 minutes&lt;br /&gt;
| metabolism = Liver glucuronidation&lt;br /&gt;
| halflife_redistribution = 2-8 minutes (initial)&lt;br /&gt;
30-70 minutes (slow)&lt;br /&gt;
| halflife_elimination = 1.5-31 hours&lt;br /&gt;
| clearance = 1.5-2.2 L/min&lt;br /&gt;
| protein_binding = 95-99%&lt;br /&gt;
| pka = 11&lt;br /&gt;
| volume_distribution = 6-40 L (central)&lt;br /&gt;
150-700 L (steady state)&lt;br /&gt;
| formula = C&amp;lt;sub&amp;gt;12&amp;lt;/sub&amp;gt;H&amp;lt;sub&amp;gt;18&amp;lt;/sub&amp;gt;O&lt;br /&gt;
| molar_mass = 178.275 g/mol&lt;br /&gt;
}}Provide a brief summary of this drug here. Test. Another test. Yet another test. Wooooooo&lt;br /&gt;
&lt;br /&gt;
==Uses&amp;lt;!-- Describe uses of the drug. If appropriate, add subsections for each indication. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
==Contraindications&amp;lt;!-- List contraindications and precautions for use of the drug. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
===Absolute contraindications&amp;lt;!-- List absolute contraindications for use of the drug. If none, this section may be removed. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
===Precautions&amp;lt;!-- List precautions for use of the drug. If none, this section may be removed. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
==Pharmacology==&lt;br /&gt;
&lt;br /&gt;
===Pharmacodynamics&amp;lt;!-- Describe the effects of the drug on the body. If appropriate, add subsections by organ system --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
====Mechanism of action&amp;lt;!-- Describe the mechanism of action for the primary uses of the drug. --&amp;gt;====&lt;br /&gt;
&lt;br /&gt;
====Adverse effects&amp;lt;!-- Describe any potential adverse effects of the drug. --&amp;gt;====&lt;br /&gt;
[[File:Hilton Worldwide logo.svg|thumb]]&lt;br /&gt;
&lt;br /&gt;
===Pharmacokinetics&amp;lt;!-- Describe the pharmacokinetics of the drug. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
==Chemistry and formulation&amp;lt;!-- Describe the chemistry and formulation of the drug. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
==History&amp;lt;!-- Describe the historical development of the drug. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
==References==&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Propofol&amp;diff=4639</id>
		<title>Propofol</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Propofol&amp;diff=4639"/>
		<updated>2022-03-17T09:58:41Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox drug reference&lt;br /&gt;
| trade_names = Diprivan&lt;br /&gt;
| image_file = Propofol.png&lt;br /&gt;
| image_caption = &lt;br /&gt;
| drug_class = Sedative hypnotic&lt;br /&gt;
| drug_class_color = sedative_hypnotic&lt;br /&gt;
| uses = Induction and maintenance of anesthesia, sedation&lt;br /&gt;
| contraindications = Egg/soy allergy (controversial)&lt;br /&gt;
| routes = Intravenous&lt;br /&gt;
| dosage = Induction of anesthesia:&lt;br /&gt;
* Adult: 1-2.5 mg/kg&lt;br /&gt;
* Elderly: 1-1.5 mg/kg&lt;br /&gt;
* Pediatric: 2.5-3.5 mg/kg&lt;br /&gt;
Maintenance of anesthesia:&lt;br /&gt;
* Adult: 100-200 mcg/kg/min&lt;br /&gt;
* Elderly: 50-100 mcg/kg/min&lt;br /&gt;
* Pediatric: 125-300 mcg/kg/min&lt;br /&gt;
| mechanism = GABA agonism&lt;br /&gt;
| adverse_effects = Hypotension&lt;br /&gt;
Bradycardia&lt;br /&gt;
Pain on injection&lt;br /&gt;
| time_onset = 15-30 seconds&lt;br /&gt;
| duration = 5-10 minutes&lt;br /&gt;
| metabolism = Liver glucuronidation&lt;br /&gt;
| halflife_redistribution = 2-8 minutes (initial)&lt;br /&gt;
30-70 minutes (slow)&lt;br /&gt;
| halflife_elimination = 1.5-31 hours&lt;br /&gt;
| clearance = 1.5-2.2 L/min&lt;br /&gt;
| protein_binding = 95-99%&lt;br /&gt;
| pka = 11&lt;br /&gt;
| volume_distribution = 6-40 L (central)&lt;br /&gt;
150-700 L (steady state)&lt;br /&gt;
| formula = C&amp;lt;sub&amp;gt;12&amp;lt;/sub&amp;gt;H&amp;lt;sub&amp;gt;18&amp;lt;/sub&amp;gt;O&lt;br /&gt;
| molar_mass = 178.275 g/mol&lt;br /&gt;
}}Provide a brief summary of this drug here. Test. Another test. Yet another test. Woooooo&lt;br /&gt;
&lt;br /&gt;
==Uses&amp;lt;!-- Describe uses of the drug. If appropriate, add subsections for each indication. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
==Contraindications&amp;lt;!-- List contraindications and precautions for use of the drug. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
===Absolute contraindications&amp;lt;!-- List absolute contraindications for use of the drug. If none, this section may be removed. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
===Precautions&amp;lt;!-- List precautions for use of the drug. If none, this section may be removed. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
==Pharmacology==&lt;br /&gt;
&lt;br /&gt;
===Pharmacodynamics&amp;lt;!-- Describe the effects of the drug on the body. If appropriate, add subsections by organ system --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
====Mechanism of action&amp;lt;!-- Describe the mechanism of action for the primary uses of the drug. --&amp;gt;====&lt;br /&gt;
&lt;br /&gt;
====Adverse effects&amp;lt;!-- Describe any potential adverse effects of the drug. --&amp;gt;====&lt;br /&gt;
[[File:Hilton Worldwide logo.svg|thumb]]&lt;br /&gt;
&lt;br /&gt;
===Pharmacokinetics&amp;lt;!-- Describe the pharmacokinetics of the drug. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
==Chemistry and formulation&amp;lt;!-- Describe the chemistry and formulation of the drug. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
==History&amp;lt;!-- Describe the historical development of the drug. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
==References==&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Propofol&amp;diff=4638</id>
		<title>Propofol</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Propofol&amp;diff=4638"/>
		<updated>2022-03-17T09:53:10Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox drug reference&lt;br /&gt;
| trade_names = Diprivan&lt;br /&gt;
| image_file = Propofol.png&lt;br /&gt;
| image_caption = &lt;br /&gt;
| drug_class = Sedative hypnotic&lt;br /&gt;
| drug_class_color = sedative_hypnotic&lt;br /&gt;
| uses = Induction and maintenance of anesthesia, sedation&lt;br /&gt;
| contraindications = Egg/soy allergy (controversial)&lt;br /&gt;
| routes = Intravenous&lt;br /&gt;
| dosage = Induction of anesthesia:&lt;br /&gt;
* Adult: 1-2.5 mg/kg&lt;br /&gt;
* Elderly: 1-1.5 mg/kg&lt;br /&gt;
* Pediatric: 2.5-3.5 mg/kg&lt;br /&gt;
Maintenance of anesthesia:&lt;br /&gt;
* Adult: 100-200 mcg/kg/min&lt;br /&gt;
* Elderly: 50-100 mcg/kg/min&lt;br /&gt;
* Pediatric: 125-300 mcg/kg/min&lt;br /&gt;
| mechanism = GABA agonism&lt;br /&gt;
| adverse_effects = Hypotension&lt;br /&gt;
Bradycardia&lt;br /&gt;
Pain on injection&lt;br /&gt;
| time_onset = 15-30 seconds&lt;br /&gt;
| duration = 5-10 minutes&lt;br /&gt;
| metabolism = Liver glucuronidation&lt;br /&gt;
| halflife_redistribution = 2-8 minutes (initial)&lt;br /&gt;
30-70 minutes (slow)&lt;br /&gt;
| halflife_elimination = 1.5-31 hours&lt;br /&gt;
| clearance = 1.5-2.2 L/min&lt;br /&gt;
| protein_binding = 95-99%&lt;br /&gt;
| pka = 11&lt;br /&gt;
| volume_distribution = 6-40 L (central)&lt;br /&gt;
150-700 L (steady state)&lt;br /&gt;
| formula = C&amp;lt;sub&amp;gt;12&amp;lt;/sub&amp;gt;H&amp;lt;sub&amp;gt;18&amp;lt;/sub&amp;gt;O&lt;br /&gt;
| molar_mass = 178.275 g/mol&lt;br /&gt;
}}Provide a brief summary of this drug here. Test. Another test. Yet another test. Wooooo&lt;br /&gt;
&lt;br /&gt;
==Uses&amp;lt;!-- Describe uses of the drug. If appropriate, add subsections for each indication. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
==Contraindications&amp;lt;!-- List contraindications and precautions for use of the drug. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
===Absolute contraindications&amp;lt;!-- List absolute contraindications for use of the drug. If none, this section may be removed. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
===Precautions&amp;lt;!-- List precautions for use of the drug. If none, this section may be removed. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
==Pharmacology==&lt;br /&gt;
&lt;br /&gt;
===Pharmacodynamics&amp;lt;!-- Describe the effects of the drug on the body. If appropriate, add subsections by organ system --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
====Mechanism of action&amp;lt;!-- Describe the mechanism of action for the primary uses of the drug. --&amp;gt;====&lt;br /&gt;
&lt;br /&gt;
====Adverse effects&amp;lt;!-- Describe any potential adverse effects of the drug. --&amp;gt;====&lt;br /&gt;
[[File:Hilton Worldwide logo.svg|thumb]]&lt;br /&gt;
&lt;br /&gt;
===Pharmacokinetics&amp;lt;!-- Describe the pharmacokinetics of the drug. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
==Chemistry and formulation&amp;lt;!-- Describe the chemistry and formulation of the drug. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
==History&amp;lt;!-- Describe the historical development of the drug. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
==References==&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Propofol&amp;diff=4637</id>
		<title>Propofol</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Propofol&amp;diff=4637"/>
		<updated>2022-03-17T09:51:30Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox drug reference&lt;br /&gt;
| trade_names = Diprivan&lt;br /&gt;
| image_file = Propofol.png&lt;br /&gt;
| image_caption = &lt;br /&gt;
| drug_class = Sedative hypnotic&lt;br /&gt;
| drug_class_color = sedative_hypnotic&lt;br /&gt;
| uses = Induction and maintenance of anesthesia, sedation&lt;br /&gt;
| contraindications = Egg/soy allergy (controversial)&lt;br /&gt;
| routes = Intravenous&lt;br /&gt;
| dosage = Induction of anesthesia:&lt;br /&gt;
* Adult: 1-2.5 mg/kg&lt;br /&gt;
* Elderly: 1-1.5 mg/kg&lt;br /&gt;
* Pediatric: 2.5-3.5 mg/kg&lt;br /&gt;
Maintenance of anesthesia:&lt;br /&gt;
* Adult: 100-200 mcg/kg/min&lt;br /&gt;
* Elderly: 50-100 mcg/kg/min&lt;br /&gt;
* Pediatric: 125-300 mcg/kg/min&lt;br /&gt;
| mechanism = GABA agonism&lt;br /&gt;
| adverse_effects = Hypotension&lt;br /&gt;
Bradycardia&lt;br /&gt;
Pain on injection&lt;br /&gt;
| time_onset = 15-30 seconds&lt;br /&gt;
| duration = 5-10 minutes&lt;br /&gt;
| metabolism = Liver glucuronidation&lt;br /&gt;
| halflife_redistribution = 2-8 minutes (initial)&lt;br /&gt;
30-70 minutes (slow)&lt;br /&gt;
| halflife_elimination = 1.5-31 hours&lt;br /&gt;
| clearance = 1.5-2.2 L/min&lt;br /&gt;
| protein_binding = 95-99%&lt;br /&gt;
| pka = 11&lt;br /&gt;
| volume_distribution = 6-40 L (central)&lt;br /&gt;
150-700 L (steady state)&lt;br /&gt;
| formula = C&amp;lt;sub&amp;gt;12&amp;lt;/sub&amp;gt;H&amp;lt;sub&amp;gt;18&amp;lt;/sub&amp;gt;O&lt;br /&gt;
| molar_mass = 178.275 g/mol&lt;br /&gt;
}}Provide a brief summary of this drug here. Test. Another test. Yet another test. Woooo&lt;br /&gt;
&lt;br /&gt;
==Uses&amp;lt;!-- Describe uses of the drug. If appropriate, add subsections for each indication. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
==Contraindications&amp;lt;!-- List contraindications and precautions for use of the drug. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
===Absolute contraindications&amp;lt;!-- List absolute contraindications for use of the drug. If none, this section may be removed. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
===Precautions&amp;lt;!-- List precautions for use of the drug. If none, this section may be removed. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
==Pharmacology==&lt;br /&gt;
&lt;br /&gt;
===Pharmacodynamics&amp;lt;!-- Describe the effects of the drug on the body. If appropriate, add subsections by organ system --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
====Mechanism of action&amp;lt;!-- Describe the mechanism of action for the primary uses of the drug. --&amp;gt;====&lt;br /&gt;
&lt;br /&gt;
====Adverse effects&amp;lt;!-- Describe any potential adverse effects of the drug. --&amp;gt;====&lt;br /&gt;
[[File:Hilton Worldwide logo.svg|thumb]]&lt;br /&gt;
&lt;br /&gt;
===Pharmacokinetics&amp;lt;!-- Describe the pharmacokinetics of the drug. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
==Chemistry and formulation&amp;lt;!-- Describe the chemistry and formulation of the drug. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
==History&amp;lt;!-- Describe the historical development of the drug. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
==References==&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Propofol&amp;diff=4636</id>
		<title>Propofol</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Propofol&amp;diff=4636"/>
		<updated>2022-03-17T09:48:55Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox drug reference&lt;br /&gt;
| trade_names = Diprivan&lt;br /&gt;
| image_file = Propofol.png&lt;br /&gt;
| image_caption = &lt;br /&gt;
| drug_class = Sedative hypnotic&lt;br /&gt;
| drug_class_color = sedative_hypnotic&lt;br /&gt;
| uses = Induction and maintenance of anesthesia, sedation&lt;br /&gt;
| contraindications = Egg/soy allergy (controversial)&lt;br /&gt;
| routes = Intravenous&lt;br /&gt;
| dosage = Induction of anesthesia:&lt;br /&gt;
* Adult: 1-2.5 mg/kg&lt;br /&gt;
* Elderly: 1-1.5 mg/kg&lt;br /&gt;
* Pediatric: 2.5-3.5 mg/kg&lt;br /&gt;
Maintenance of anesthesia:&lt;br /&gt;
* Adult: 100-200 mcg/kg/min&lt;br /&gt;
* Elderly: 50-100 mcg/kg/min&lt;br /&gt;
* Pediatric: 125-300 mcg/kg/min&lt;br /&gt;
| mechanism = GABA agonism&lt;br /&gt;
| adverse_effects = Hypotension&lt;br /&gt;
Bradycardia&lt;br /&gt;
Pain on injection&lt;br /&gt;
| time_onset = 15-30 seconds&lt;br /&gt;
| duration = 5-10 minutes&lt;br /&gt;
| metabolism = Liver glucuronidation&lt;br /&gt;
| halflife_redistribution = 2-8 minutes (initial)&lt;br /&gt;
30-70 minutes (slow)&lt;br /&gt;
| halflife_elimination = 1.5-31 hours&lt;br /&gt;
| clearance = 1.5-2.2 L/min&lt;br /&gt;
| protein_binding = 95-99%&lt;br /&gt;
| pka = 11&lt;br /&gt;
| volume_distribution = 6-40 L (central)&lt;br /&gt;
150-700 L (steady state)&lt;br /&gt;
| formula = C&amp;lt;sub&amp;gt;12&amp;lt;/sub&amp;gt;H&amp;lt;sub&amp;gt;18&amp;lt;/sub&amp;gt;O&lt;br /&gt;
| molar_mass = 178.275 g/mol&lt;br /&gt;
}}Provide a brief summary of this drug here. Test. Another test. Yet another test. Wooo&lt;br /&gt;
&lt;br /&gt;
==Uses&amp;lt;!-- Describe uses of the drug. If appropriate, add subsections for each indication. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
==Contraindications&amp;lt;!-- List contraindications and precautions for use of the drug. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
===Absolute contraindications&amp;lt;!-- List absolute contraindications for use of the drug. If none, this section may be removed. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
===Precautions&amp;lt;!-- List precautions for use of the drug. If none, this section may be removed. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
==Pharmacology==&lt;br /&gt;
&lt;br /&gt;
===Pharmacodynamics&amp;lt;!-- Describe the effects of the drug on the body. If appropriate, add subsections by organ system --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
====Mechanism of action&amp;lt;!-- Describe the mechanism of action for the primary uses of the drug. --&amp;gt;====&lt;br /&gt;
&lt;br /&gt;
====Adverse effects&amp;lt;!-- Describe any potential adverse effects of the drug. --&amp;gt;====&lt;br /&gt;
[[File:Hilton Worldwide logo.svg|thumb]]&lt;br /&gt;
&lt;br /&gt;
===Pharmacokinetics&amp;lt;!-- Describe the pharmacokinetics of the drug. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
==Chemistry and formulation&amp;lt;!-- Describe the chemistry and formulation of the drug. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
==History&amp;lt;!-- Describe the historical development of the drug. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
==References==&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Propofol&amp;diff=4635</id>
		<title>Propofol</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Propofol&amp;diff=4635"/>
		<updated>2022-03-17T09:47:34Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox drug reference&lt;br /&gt;
| trade_names = Diprivan&lt;br /&gt;
| image_file = Propofol.png&lt;br /&gt;
| image_caption = &lt;br /&gt;
| drug_class = Sedative hypnotic&lt;br /&gt;
| drug_class_color = sedative_hypnotic&lt;br /&gt;
| uses = Induction and maintenance of anesthesia, sedation&lt;br /&gt;
| contraindications = Egg/soy allergy (controversial)&lt;br /&gt;
| routes = Intravenous&lt;br /&gt;
| dosage = Induction of anesthesia:&lt;br /&gt;
* Adult: 1-2.5 mg/kg&lt;br /&gt;
* Elderly: 1-1.5 mg/kg&lt;br /&gt;
* Pediatric: 2.5-3.5 mg/kg&lt;br /&gt;
Maintenance of anesthesia:&lt;br /&gt;
* Adult: 100-200 mcg/kg/min&lt;br /&gt;
* Elderly: 50-100 mcg/kg/min&lt;br /&gt;
* Pediatric: 125-300 mcg/kg/min&lt;br /&gt;
| mechanism = GABA agonism&lt;br /&gt;
| adverse_effects = Hypotension&lt;br /&gt;
Bradycardia&lt;br /&gt;
Pain on injection&lt;br /&gt;
| time_onset = 15-30 seconds&lt;br /&gt;
| duration = 5-10 minutes&lt;br /&gt;
| metabolism = Liver glucuronidation&lt;br /&gt;
| halflife_redistribution = 2-8 minutes (initial)&lt;br /&gt;
30-70 minutes (slow)&lt;br /&gt;
| halflife_elimination = 1.5-31 hours&lt;br /&gt;
| clearance = 1.5-2.2 L/min&lt;br /&gt;
| protein_binding = 95-99%&lt;br /&gt;
| pka = 11&lt;br /&gt;
| volume_distribution = 6-40 L (central)&lt;br /&gt;
150-700 L (steady state)&lt;br /&gt;
| formula = C&amp;lt;sub&amp;gt;12&amp;lt;/sub&amp;gt;H&amp;lt;sub&amp;gt;18&amp;lt;/sub&amp;gt;O&lt;br /&gt;
| molar_mass = 178.275 g/mol&lt;br /&gt;
}}Provide a brief summary of this drug here. Test. Another test. Yet another test. Woo&lt;br /&gt;
&lt;br /&gt;
==Uses&amp;lt;!-- Describe uses of the drug. If appropriate, add subsections for each indication. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
==Contraindications&amp;lt;!-- List contraindications and precautions for use of the drug. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
===Absolute contraindications&amp;lt;!-- List absolute contraindications for use of the drug. If none, this section may be removed. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
===Precautions&amp;lt;!-- List precautions for use of the drug. If none, this section may be removed. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
==Pharmacology==&lt;br /&gt;
&lt;br /&gt;
===Pharmacodynamics&amp;lt;!-- Describe the effects of the drug on the body. If appropriate, add subsections by organ system --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
====Mechanism of action&amp;lt;!-- Describe the mechanism of action for the primary uses of the drug. --&amp;gt;====&lt;br /&gt;
&lt;br /&gt;
====Adverse effects&amp;lt;!-- Describe any potential adverse effects of the drug. --&amp;gt;====&lt;br /&gt;
[[File:Hilton Worldwide logo.svg|thumb]]&lt;br /&gt;
&lt;br /&gt;
===Pharmacokinetics&amp;lt;!-- Describe the pharmacokinetics of the drug. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
==Chemistry and formulation&amp;lt;!-- Describe the chemistry and formulation of the drug. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
==History&amp;lt;!-- Describe the historical development of the drug. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
==References==&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Propofol&amp;diff=4634</id>
		<title>Propofol</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Propofol&amp;diff=4634"/>
		<updated>2022-03-17T09:35:27Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox drug reference&lt;br /&gt;
| trade_names = Diprivan&lt;br /&gt;
| image_file = Propofol.png&lt;br /&gt;
| image_caption = &lt;br /&gt;
| drug_class = Sedative hypnotic&lt;br /&gt;
| drug_class_color = sedative_hypnotic&lt;br /&gt;
| uses = Induction and maintenance of anesthesia, sedation&lt;br /&gt;
| contraindications = Egg/soy allergy (controversial)&lt;br /&gt;
| routes = Intravenous&lt;br /&gt;
| dosage = Induction of anesthesia:&lt;br /&gt;
* Adult: 1-2.5 mg/kg&lt;br /&gt;
* Elderly: 1-1.5 mg/kg&lt;br /&gt;
* Pediatric: 2.5-3.5 mg/kg&lt;br /&gt;
Maintenance of anesthesia:&lt;br /&gt;
* Adult: 100-200 mcg/kg/min&lt;br /&gt;
* Elderly: 50-100 mcg/kg/min&lt;br /&gt;
* Pediatric: 125-300 mcg/kg/min&lt;br /&gt;
| mechanism = GABA agonism&lt;br /&gt;
| adverse_effects = Hypotension&lt;br /&gt;
Bradycardia&lt;br /&gt;
Pain on injection&lt;br /&gt;
| time_onset = 15-30 seconds&lt;br /&gt;
| duration = 5-10 minutes&lt;br /&gt;
| metabolism = Liver glucuronidation&lt;br /&gt;
| halflife_redistribution = 2-8 minutes (initial)&lt;br /&gt;
30-70 minutes (slow)&lt;br /&gt;
| halflife_elimination = 1.5-31 hours&lt;br /&gt;
| clearance = 1.5-2.2 L/min&lt;br /&gt;
| protein_binding = 95-99%&lt;br /&gt;
| pka = 11&lt;br /&gt;
| volume_distribution = 6-40 L (central)&lt;br /&gt;
150-700 L (steady state)&lt;br /&gt;
| formula = C&amp;lt;sub&amp;gt;12&amp;lt;/sub&amp;gt;H&amp;lt;sub&amp;gt;18&amp;lt;/sub&amp;gt;O&lt;br /&gt;
| molar_mass = 178.275 g/mol&lt;br /&gt;
}}Provide a brief summary of this drug here. Test. Another test. Yet another test.&lt;br /&gt;
&lt;br /&gt;
==Uses&amp;lt;!-- Describe uses of the drug. If appropriate, add subsections for each indication. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
==Contraindications&amp;lt;!-- List contraindications and precautions for use of the drug. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
===Absolute contraindications&amp;lt;!-- List absolute contraindications for use of the drug. If none, this section may be removed. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
===Precautions&amp;lt;!-- List precautions for use of the drug. If none, this section may be removed. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
==Pharmacology==&lt;br /&gt;
&lt;br /&gt;
===Pharmacodynamics&amp;lt;!-- Describe the effects of the drug on the body. If appropriate, add subsections by organ system --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
====Mechanism of action&amp;lt;!-- Describe the mechanism of action for the primary uses of the drug. --&amp;gt;====&lt;br /&gt;
&lt;br /&gt;
====Adverse effects&amp;lt;!-- Describe any potential adverse effects of the drug. --&amp;gt;====&lt;br /&gt;
[[File:Hilton Worldwide logo.svg|thumb]]&lt;br /&gt;
&lt;br /&gt;
===Pharmacokinetics&amp;lt;!-- Describe the pharmacokinetics of the drug. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
==Chemistry and formulation&amp;lt;!-- Describe the chemistry and formulation of the drug. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
==History&amp;lt;!-- Describe the historical development of the drug. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
==References==&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Propofol&amp;diff=4633</id>
		<title>Propofol</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Propofol&amp;diff=4633"/>
		<updated>2022-03-17T09:33:17Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox drug reference&lt;br /&gt;
| trade_names = Diprivan&lt;br /&gt;
| image_file = Propofol.png&lt;br /&gt;
| image_caption = &lt;br /&gt;
| drug_class = Sedative hypnotic&lt;br /&gt;
| drug_class_color = sedative_hypnotic&lt;br /&gt;
| uses = Induction and maintenance of anesthesia, sedation&lt;br /&gt;
| contraindications = Egg/soy allergy (controversial)&lt;br /&gt;
| routes = Intravenous&lt;br /&gt;
| dosage = Induction of anesthesia:&lt;br /&gt;
* Adult: 1-2.5 mg/kg&lt;br /&gt;
* Elderly: 1-1.5 mg/kg&lt;br /&gt;
* Pediatric: 2.5-3.5 mg/kg&lt;br /&gt;
Maintenance of anesthesia:&lt;br /&gt;
* Adult: 100-200 mcg/kg/min&lt;br /&gt;
* Elderly: 50-100 mcg/kg/min&lt;br /&gt;
* Pediatric: 125-300 mcg/kg/min&lt;br /&gt;
| mechanism = GABA agonism&lt;br /&gt;
| adverse_effects = Hypotension&lt;br /&gt;
Bradycardia&lt;br /&gt;
Pain on injection&lt;br /&gt;
| time_onset = 15-30 seconds&lt;br /&gt;
| duration = 5-10 minutes&lt;br /&gt;
| metabolism = Liver glucuronidation&lt;br /&gt;
| halflife_redistribution = 2-8 minutes (initial)&lt;br /&gt;
30-70 minutes (slow)&lt;br /&gt;
| halflife_elimination = 1.5-31 hours&lt;br /&gt;
| clearance = 1.5-2.2 L/min&lt;br /&gt;
| protein_binding = 95-99%&lt;br /&gt;
| pka = 11&lt;br /&gt;
| volume_distribution = 6-40 L (central)&lt;br /&gt;
150-700 L (steady state)&lt;br /&gt;
| formula = C&amp;lt;sub&amp;gt;12&amp;lt;/sub&amp;gt;H&amp;lt;sub&amp;gt;18&amp;lt;/sub&amp;gt;O&lt;br /&gt;
| molar_mass = 178.275 g/mol&lt;br /&gt;
}}Provide a brief summary of this drug here. Test. Another test.&lt;br /&gt;
&lt;br /&gt;
==Uses&amp;lt;!-- Describe uses of the drug. If appropriate, add subsections for each indication. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
==Contraindications&amp;lt;!-- List contraindications and precautions for use of the drug. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
===Absolute contraindications&amp;lt;!-- List absolute contraindications for use of the drug. If none, this section may be removed. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
===Precautions&amp;lt;!-- List precautions for use of the drug. If none, this section may be removed. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
==Pharmacology==&lt;br /&gt;
&lt;br /&gt;
===Pharmacodynamics&amp;lt;!-- Describe the effects of the drug on the body. If appropriate, add subsections by organ system --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
====Mechanism of action&amp;lt;!-- Describe the mechanism of action for the primary uses of the drug. --&amp;gt;====&lt;br /&gt;
&lt;br /&gt;
====Adverse effects&amp;lt;!-- Describe any potential adverse effects of the drug. --&amp;gt;====&lt;br /&gt;
[[File:Hilton Worldwide logo.svg|thumb]]&lt;br /&gt;
&lt;br /&gt;
===Pharmacokinetics&amp;lt;!-- Describe the pharmacokinetics of the drug. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
==Chemistry and formulation&amp;lt;!-- Describe the chemistry and formulation of the drug. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
==History&amp;lt;!-- Describe the historical development of the drug. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
==References==&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Propofol&amp;diff=4632</id>
		<title>Propofol</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Propofol&amp;diff=4632"/>
		<updated>2022-03-17T09:31:37Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox drug reference&lt;br /&gt;
| trade_names = Diprivan&lt;br /&gt;
| image_file = Propofol.png&lt;br /&gt;
| image_caption = &lt;br /&gt;
| drug_class = Sedative hypnotic&lt;br /&gt;
| drug_class_color = sedative_hypnotic&lt;br /&gt;
| uses = Induction and maintenance of anesthesia, sedation&lt;br /&gt;
| contraindications = Egg/soy allergy (controversial)&lt;br /&gt;
| routes = Intravenous&lt;br /&gt;
| dosage = Induction of anesthesia:&lt;br /&gt;
* Adult: 1-2.5 mg/kg&lt;br /&gt;
* Elderly: 1-1.5 mg/kg&lt;br /&gt;
* Pediatric: 2.5-3.5 mg/kg&lt;br /&gt;
Maintenance of anesthesia:&lt;br /&gt;
* Adult: 100-200 mcg/kg/min&lt;br /&gt;
* Elderly: 50-100 mcg/kg/min&lt;br /&gt;
* Pediatric: 125-300 mcg/kg/min&lt;br /&gt;
| mechanism = GABA agonism&lt;br /&gt;
| adverse_effects = Hypotension&lt;br /&gt;
Bradycardia&lt;br /&gt;
Pain on injection&lt;br /&gt;
| time_onset = 15-30 seconds&lt;br /&gt;
| duration = 5-10 minutes&lt;br /&gt;
| metabolism = Liver glucuronidation&lt;br /&gt;
| halflife_redistribution = 2-8 minutes (initial)&lt;br /&gt;
30-70 minutes (slow)&lt;br /&gt;
| halflife_elimination = 1.5-31 hours&lt;br /&gt;
| clearance = 1.5-2.2 L/min&lt;br /&gt;
| protein_binding = 95-99%&lt;br /&gt;
| pka = 11&lt;br /&gt;
| volume_distribution = 6-40 L (central)&lt;br /&gt;
150-700 L (steady state)&lt;br /&gt;
| formula = C&amp;lt;sub&amp;gt;12&amp;lt;/sub&amp;gt;H&amp;lt;sub&amp;gt;18&amp;lt;/sub&amp;gt;O&lt;br /&gt;
| molar_mass = 178.275 g/mol&lt;br /&gt;
}}Provide a brief summary of this drug here. Test&lt;br /&gt;
&lt;br /&gt;
==Uses&amp;lt;!-- Describe uses of the drug. If appropriate, add subsections for each indication. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
==Contraindications&amp;lt;!-- List contraindications and precautions for use of the drug. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
===Absolute contraindications&amp;lt;!-- List absolute contraindications for use of the drug. If none, this section may be removed. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
===Precautions&amp;lt;!-- List precautions for use of the drug. If none, this section may be removed. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
==Pharmacology==&lt;br /&gt;
&lt;br /&gt;
===Pharmacodynamics&amp;lt;!-- Describe the effects of the drug on the body. If appropriate, add subsections by organ system --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
====Mechanism of action&amp;lt;!-- Describe the mechanism of action for the primary uses of the drug. --&amp;gt;====&lt;br /&gt;
&lt;br /&gt;
====Adverse effects&amp;lt;!-- Describe any potential adverse effects of the drug. --&amp;gt;====&lt;br /&gt;
[[File:Hilton Worldwide logo.svg|thumb]]&lt;br /&gt;
&lt;br /&gt;
===Pharmacokinetics&amp;lt;!-- Describe the pharmacokinetics of the drug. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
==Chemistry and formulation&amp;lt;!-- Describe the chemistry and formulation of the drug. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
==History&amp;lt;!-- Describe the historical development of the drug. --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
==References==&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Appendectomy&amp;diff=2149</id>
		<title>Appendectomy</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Appendectomy&amp;diff=2149"/>
		<updated>2021-06-28T08:46:06Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox surgical case reference&lt;br /&gt;
| anesthesia_type = General&lt;br /&gt;
| airway = Endotracheal tube&lt;br /&gt;
| lines_access = Peripheral IV&lt;br /&gt;
| monitors = Standard ASA  /  5-Lead EKG&lt;br /&gt;
| considerations_preoperative = Full stomach precautions&lt;br /&gt;
| considerations_intraoperative = Rapid sequence induction&lt;br /&gt;
| considerations_postoperative = PONV&lt;br /&gt;
| image_file = &lt;br /&gt;
}}An appendectomy is generally performed as an urgent or emergent procedure to treat appendicitis. Appendicitis can occur at any age, but is more common in patients 19-25 years old.  Appendicitis is common, occurring in about 7% of the population.  An appendectomy can be performed laparoscopically or as an open procedure.  Surgical practice has largely transitioned to the laparoscopic approach&amp;lt;ref&amp;gt;{{Cite journal|last=Bhangu|first=Aneel|last2=Søreide|first2=Kjetil|last3=Di Saverio|first3=Salomone|last4=Assarsson|first4=Jeanette Hansson|last5=Drake|first5=Frederick Thurston|date=2015|title=Acute appendicitis: modern understanding of pathogenesis, diagnosis, and management|url=https://linkinghub.elsevier.com/retrieve/pii/S0140673615002755|journal=The Lancet|language=en|volume=386|issue=10000|pages=1278–1287|doi=10.1016/S0140-6736(15)00275-5|via=}}&amp;lt;/ref&amp;gt;.     &lt;br /&gt;
==Preoperative management==&lt;br /&gt;
===Preoperative evaluation&amp;lt;!-- Provide a brief overview of the preoperative evaluation and optimization of patients for this case. Also list relevant labs, studies, or physical exam findings. If none, this section may be removed. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|+&lt;br /&gt;
!System&lt;br /&gt;
!Considerations&lt;br /&gt;
|-&lt;br /&gt;
|Respiratory&lt;br /&gt;
|&lt;br /&gt;
* Acute abdominal pain can cause respiratory impairment (respiratory splinting) resulting in atelectasis&lt;br /&gt;
|-&lt;br /&gt;
|Cardiovascular&lt;br /&gt;
|&lt;br /&gt;
* May be dehydrated due to fever, emesis, and reduced oral intake&lt;br /&gt;
* Assess volume status by checking vital signs, mucus membranes, skin turgor.&lt;br /&gt;
* IV hydration before anesthetic induction as patients may be volume depleted&lt;br /&gt;
|-&lt;br /&gt;
|Gastrointestinal&lt;br /&gt;
|&lt;br /&gt;
* Patients typically present with nausea and vomiting.  &lt;br /&gt;
&lt;br /&gt;
* Use full stomach precautions&lt;br /&gt;
&lt;br /&gt;
* Muscular resistance to palpation (muscle guarding) can correlate with severity of the inflammatory process.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|Hematologic&lt;br /&gt;
|&lt;br /&gt;
* Patients typically have moderate leukocytosis with left shift&lt;br /&gt;
* Expect hemoconcentration if patient dehydrated&lt;br /&gt;
|-&lt;br /&gt;
|Labs&lt;br /&gt;
|&lt;br /&gt;
* CBC&lt;br /&gt;
* Chemistry Panel&lt;br /&gt;
* Pregnancy test (for women of child bearing age)&lt;br /&gt;
|}&lt;br /&gt;
* &lt;br /&gt;
&lt;br /&gt;
===Operating room preparation&amp;lt;!-- List any special, non-standard equipment, medications, fluids, or other preparations that should be made prior to surgery. If none, this section may be removed. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
* NG Tube&lt;br /&gt;
* Verify pre-incisions antibiotics required&lt;br /&gt;
&lt;br /&gt;
=== Regional and neuraxial techniques ===&lt;br /&gt;
&lt;br /&gt;
* Consider pre-incision nerve blocks. Bilateral TAP blocks may be useful in open approach.&lt;br /&gt;
&lt;br /&gt;
==Intraoperative management==&lt;br /&gt;
===Monitoring and access&amp;lt;!-- List and/or describe monitors and access typically needed for this case. Please describe rationale for any special monitors or access. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
* Standard ASA monitors&lt;br /&gt;
* 5-lead EKG&lt;br /&gt;
* Urinary catheter&lt;br /&gt;
* 1 peripheral IV (typically 16-18 gauge)&lt;br /&gt;
* &lt;br /&gt;
&lt;br /&gt;
===Induction and airway management&amp;lt;!-- Describe the important considerations and general approach to the induction of anesthesia and how the airway is typically managed for this case. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
* Pre-oxygenate with 100% FiO2&lt;br /&gt;
* Rapid Sequence Induction (RSI) &lt;br /&gt;
* Intubation&lt;br /&gt;
* &lt;br /&gt;
&lt;br /&gt;
===Positioning&amp;lt;!-- Describe any unique positioning considerations, including potential intraoperative position changes. If none, this section may be removed. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
* Supine&lt;br /&gt;
* Secure or tuck the arms&lt;br /&gt;
* Check angle of arm&lt;br /&gt;
&lt;br /&gt;
===Maintenance and surgical considerations&amp;lt;!-- Describe the important considerations and general approach to the maintenance of anesthesia, including potential complications. Be sure to include any steps to the surgical procedure that have anesthetic implications. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
* Standard maintenance &lt;br /&gt;
** Consider avoiding nitrous oxide given potential for bowel dissension and increased risk of PONV&lt;br /&gt;
* Place OG/NG before surgical incision to decompress the stomach&lt;br /&gt;
* Maintain normovolemia and normothermia&lt;br /&gt;
&lt;br /&gt;
===Emergence&amp;lt;!-- List and/or describe any important considerations related to the emergence from anesthesia for this case. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
* Extubate when patient awake and able to protect airway&lt;br /&gt;
* PONV prophylaxis&lt;br /&gt;
&lt;br /&gt;
==Postoperative management==&lt;br /&gt;
===Disposition&amp;lt;!-- List and/or describe the postoperative disposition and any special considerations for transport of patients for this case. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
* PACU&lt;br /&gt;
** Patients undergoing laparoscopic appendectomy can often be discharged home from PACU&lt;br /&gt;
* Encourage early post-operative ambulation&lt;br /&gt;
&lt;br /&gt;
===Pain management&amp;lt;!-- Describe the expected level of postoperative pain and approaches to pain management for this case. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
* Oral analgesics&lt;br /&gt;
* Non-opioid analgesics&lt;br /&gt;
** Ketoralac (Toradol)&lt;br /&gt;
** Acetaminophen (Tylenol)&lt;br /&gt;
* IV narcotics for breakthrough pain&lt;br /&gt;
&lt;br /&gt;
===Potential complications&amp;lt;!-- List and/or describe any potential postoperative complications for this case. --&amp;gt;===&lt;br /&gt;
&lt;br /&gt;
* PONV&lt;br /&gt;
** Consider multiple PONV prophylactics&lt;br /&gt;
* Urinary retention (consider straight catheterization of bladder prior to emergence)&lt;br /&gt;
* &lt;br /&gt;
&lt;br /&gt;
==Procedure variants&amp;lt;!-- This section should only be used for cases with multiple approaches (e.g. Laparoscopic vs. open appendectomy). Otherwise, remove this section. Use this table to very briefly compare and contrast various aspects between approaches. Add or remove rows as needed to maximize relevance. Consider using symbols rather than words when possible (e.g. +, –, additional symbols such as ↑ and ↓ are available using the &amp;quot;Ω&amp;quot; tool in the editor). --&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|+&lt;br /&gt;
!&lt;br /&gt;
!Open Appendectomy&lt;br /&gt;
!Laparoscopic Appendectomy&lt;br /&gt;
|-&lt;br /&gt;
|Position&lt;br /&gt;
|Supine&lt;br /&gt;
|Supine&lt;br /&gt;
|-&lt;br /&gt;
|Surgical time&lt;br /&gt;
|1 hour&lt;br /&gt;
|30-90 mins&lt;br /&gt;
|-&lt;br /&gt;
|EBL&lt;br /&gt;
|&amp;lt;75 mL&lt;br /&gt;
|&amp;lt;75 mL&lt;br /&gt;
|-&lt;br /&gt;
|Postoperative disposition&lt;br /&gt;
|PACU&lt;br /&gt;
|PACU&lt;br /&gt;
|-&lt;br /&gt;
|Mortality&lt;br /&gt;
|Perforated: 2%&lt;br /&gt;
Non-perforated: &amp;lt;0.1%&lt;br /&gt;
|Perforated: 2%&lt;br /&gt;
Non-perforated: &amp;lt;0.1%&lt;br /&gt;
|-&lt;br /&gt;
|Complications&lt;br /&gt;
|Perforation&lt;br /&gt;
Abscess&lt;br /&gt;
&lt;br /&gt;
Fistula&lt;br /&gt;
&lt;br /&gt;
Hematoma&lt;br /&gt;
&lt;br /&gt;
Illeus&lt;br /&gt;
|Perforation&lt;br /&gt;
Abscess&lt;br /&gt;
&lt;br /&gt;
Fistula&lt;br /&gt;
&lt;br /&gt;
Hematoma&lt;br /&gt;
&lt;br /&gt;
Illeus&lt;br /&gt;
&lt;br /&gt;
Conversion to Open&lt;br /&gt;
|-&lt;br /&gt;
| Pain&lt;br /&gt;
|5-7&lt;br /&gt;
|4&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==References==&lt;br /&gt;
&amp;lt;references /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Surgical procedures]]&lt;br /&gt;
[[Category:General surgery]]&lt;br /&gt;
[[Category:Intestinal surgery]]&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=TestWikiAnesthesia&amp;diff=2132</id>
		<title>TestWikiAnesthesia</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=TestWikiAnesthesia&amp;diff=2132"/>
		<updated>2021-06-17T13:11:20Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: Created page with &amp;quot;Test&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Test&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Test_3&amp;diff=705</id>
		<title>Test 3</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Test_3&amp;diff=705"/>
		<updated>2020-11-06T06:14:15Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Hello&lt;br /&gt;
&lt;br /&gt;
This is an important article! This is another edit.&amp;lt;ref&amp;gt;{{Cite journal|last=Quan|first=Hude|last2=Sundararajan|first2=Vijaya|last3=Halfon|first3=Patricia|last4=Fong|first4=Andrew|last5=Burnand|first5=Bernard|last6=Luthi|first6=Jean-Christophe|last7=Saunders|first7=L. Duncan|last8=Beck|first8=Cynthia A.|last9=Feasby|first9=Thomas E.|last10=Ghali|first10=William A.|date=2005-11|title=Coding algorithms for defining comorbidities in ICD-9-CM and ICD-10 administrative data|url=https://pubmed.ncbi.nlm.nih.gov/16224307/|journal=Medical Care|volume=43|issue=11|pages=1130–1139|doi=10.1097/01.mlr.0000182534.19832.83|issn=0025-7079|pmid=16224307}}&amp;lt;/ref&amp;gt;&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Test_3&amp;diff=701</id>
		<title>Test 3</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Test_3&amp;diff=701"/>
		<updated>2020-11-05T13:17:09Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is an important article! This is another edit.&amp;lt;ref&amp;gt;{{Cite journal|last=Quan|first=Hude|last2=Sundararajan|first2=Vijaya|last3=Halfon|first3=Patricia|last4=Fong|first4=Andrew|last5=Burnand|first5=Bernard|last6=Luthi|first6=Jean-Christophe|last7=Saunders|first7=L. Duncan|last8=Beck|first8=Cynthia A.|last9=Feasby|first9=Thomas E.|last10=Ghali|first10=William A.|date=2005-11|title=Coding algorithms for defining comorbidities in ICD-9-CM and ICD-10 administrative data|url=https://pubmed.ncbi.nlm.nih.gov/16224307/|journal=Medical Care|volume=43|issue=11|pages=1130–1139|doi=10.1097/01.mlr.0000182534.19832.83|issn=0025-7079|pmid=16224307}}&amp;lt;/ref&amp;gt;&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=700</id>
		<title>Main Page</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=700"/>
		<updated>2020-11-05T13:09:01Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Logo-mainpage-8x.png|alt=|center|frameless|upright]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;center&amp;gt;Test&amp;lt;/center&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
__NOTITLE__&lt;br /&gt;
[[Category:No credits]]&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=699</id>
		<title>Main Page</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=699"/>
		<updated>2020-11-05T12:59:13Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Logo-mainpage-8x.png|alt=|center|frameless|upright]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;center&amp;gt;Test&amp;lt;/center&amp;gt;&lt;br /&gt;
&amp;lt;right&amp;gt;Test&amp;lt;/right&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
__NOTITLE__&lt;br /&gt;
[[Category:No credits]]&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=698</id>
		<title>Main Page</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=698"/>
		<updated>2020-11-05T12:19:40Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Logo-mainpage-8x.png|alt=|center|frameless|upright]]&amp;lt;center&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Welcome to WikiAnesthesia!&lt;br /&gt;
&amp;lt;/center&amp;gt;__NOTITLE__&lt;br /&gt;
[[Category:No credits]]&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=697</id>
		<title>Main Page</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=697"/>
		<updated>2020-11-05T11:45:42Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Logo-mainpage-8x.png|alt=|center|frameless|upright]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Welcome to WikiAnesthesia!&lt;br /&gt;
__NOTITLE__&lt;br /&gt;
[[Category:No credits]]&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=696</id>
		<title>Main Page</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=696"/>
		<updated>2020-11-05T11:45:02Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Logo-mainpage-8x.png|alt=|center|frameless|upright=2.0]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Welcome to WikiAnesthesia!&lt;br /&gt;
__NOTITLE__&lt;br /&gt;
[[Category:No credits]]&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=695</id>
		<title>Main Page</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=695"/>
		<updated>2020-11-05T11:44:40Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Logo-mainpage-8x.png|alt=|center|frameless|upright]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Welcome to WikiAnesthesia!&lt;br /&gt;
__NOTITLE__&lt;br /&gt;
[[Category:No credits]]&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=694</id>
		<title>Main Page</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=694"/>
		<updated>2020-11-05T10:56:32Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Logo-mainpage-8x.png|alt=|center|frameless|500x500px]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Welcome to WikiAnesthesia!&lt;br /&gt;
__NOTITLE__&lt;br /&gt;
[[Category:No credits]]&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=693</id>
		<title>Main Page</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=693"/>
		<updated>2020-11-05T10:56:18Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Logo-mainpage-8x.png|alt=|center|frameless|500x500px]]Welcome to WikiAnesthesia!&lt;br /&gt;
__NOTITLE__&lt;br /&gt;
[[Category:No credits]]&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=692</id>
		<title>Main Page</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=692"/>
		<updated>2020-11-05T10:53:13Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
&lt;br /&gt;
[[File:Logo-mainpage-8x.png|alt=|center|frameless|500x500px]]Welcome to WikiAnesthesia!&lt;br /&gt;
__NOTITLE__&lt;br /&gt;
[[Category:No credits]]&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=691</id>
		<title>Main Page</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=691"/>
		<updated>2020-11-05T10:52:34Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
&lt;br /&gt;
[[File:Logo-mainpage-8x.png|alt=|center|frameless|500x500px]]Welcome to WikiAnesthesia!&lt;br /&gt;
{{DISPLAYTITLE:}}&lt;br /&gt;
[[Category:No credits]]&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=690</id>
		<title>Main Page</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=690"/>
		<updated>2020-11-05T10:47:01Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
&lt;br /&gt;
[[File:Logo-mainpage-8x.png|alt=|center|frameless|500x500px]]Welcome to WikiAnesthesia!&lt;br /&gt;
__NOTITLE__&lt;br /&gt;
[[Category:No credits]]&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=689</id>
		<title>Main Page</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=689"/>
		<updated>2020-11-05T10:46:43Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[File:Logo-mainpage-8x.png|alt=|center|frameless|500x500px]]Welcome to WikiAnesthesia!&lt;br /&gt;
__NOTITLE__&lt;br /&gt;
[[Category:No credits]]&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=688</id>
		<title>Main Page</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=688"/>
		<updated>2020-11-05T10:46:20Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[File:Logo-mainpage-8x.png|alt=|center|frameless|500x500px]]&lt;br /&gt;
__NOTITLE__&lt;br /&gt;
[[Category:No credits]]&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=683</id>
		<title>Main Page</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=683"/>
		<updated>2020-11-05T10:36:46Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;strong&amp;gt;MediaWiki has been installed.&amp;lt;/strong&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Consult the [[mediawikiwiki:Special:MyLanguage/Help:Contents|User's Guide]] for information on using the wiki software. Hooray!!! Test!!!! Hmm Hello!!!!&lt;br /&gt;
&lt;br /&gt;
==Getting started ==&lt;br /&gt;
&lt;br /&gt;
*[[mediawikiwiki:Special:MyLanguage/Manual:Configuration_settings|Configuration settings list]]&lt;br /&gt;
*[[mediawikiwiki:Special:MyLanguage/Manual:FAQ|MediaWiki FAQ]]&lt;br /&gt;
*[https://lists.wikimedia.org/mailman/listinfo/mediawiki-announce MediaWiki release mailing list]&lt;br /&gt;
*[[mediawikiwiki:Special:MyLanguage/Localisation#Translation_resources|Localise MediaWiki for your language]]&lt;br /&gt;
*[[mediawikiwiki:Special:MyLanguage/Manual:Combating_spam|Learn how to combat spam on your wiki]]&lt;br /&gt;
&lt;br /&gt;
__NOTITLE__&lt;br /&gt;
[[Category:No credits]]&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=682</id>
		<title>Main Page</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=682"/>
		<updated>2020-11-04T07:57:07Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;strong&amp;gt;MediaWiki has been installed.&amp;lt;/strong&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Consult the [[mediawikiwiki:Special:MyLanguage/Help:Contents|User's Guide]] for information on using the wiki software. Hooray!!! Test!!!! Hmm Hello!!!!&lt;br /&gt;
&lt;br /&gt;
==Getting started ==&lt;br /&gt;
&lt;br /&gt;
*[[mediawikiwiki:Special:MyLanguage/Manual:Configuration_settings|Configuration settings list]]&lt;br /&gt;
*[[mediawikiwiki:Special:MyLanguage/Manual:FAQ|MediaWiki FAQ]]&lt;br /&gt;
*[https://lists.wikimedia.org/mailman/listinfo/mediawiki-announce MediaWiki release mailing list]&lt;br /&gt;
*[[mediawikiwiki:Special:MyLanguage/Localisation#Translation_resources|Localise MediaWiki for your language]]&lt;br /&gt;
*[[mediawikiwiki:Special:MyLanguage/Manual:Combating_spam|Learn how to combat spam on your wiki]]&lt;br /&gt;
&lt;br /&gt;
[[Category:No credits]]&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=649</id>
		<title>Main Page</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=649"/>
		<updated>2020-11-01T21:05:54Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: Protected &amp;quot;Main Page&amp;quot; ([Edit=Allow only administrators] (indefinite) [Move=Allow only administrators] (indefinite))&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;strong&amp;gt;MediaWiki has been installed.&amp;lt;/strong&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Consult the [[mediawikiwiki:Special:MyLanguage/Help:Contents|User's Guide]] for information on using the wiki software. Hooray!!! Test!!!! Hmm Hello!!!!&lt;br /&gt;
&lt;br /&gt;
==Getting started ==&lt;br /&gt;
&lt;br /&gt;
*[[mediawikiwiki:Special:MyLanguage/Manual:Configuration_settings|Configuration settings list]]&lt;br /&gt;
*[[mediawikiwiki:Special:MyLanguage/Manual:FAQ|MediaWiki FAQ]]&lt;br /&gt;
*[https://lists.wikimedia.org/mailman/listinfo/mediawiki-announce MediaWiki release mailing list]&lt;br /&gt;
*[[mediawikiwiki:Special:MyLanguage/Localisation#Translation_resources|Localise MediaWiki for your language]]&lt;br /&gt;
*[[mediawikiwiki:Special:MyLanguage/Manual:Combating_spam|Learn how to combat spam on your wiki]]&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=646</id>
		<title>Main Page</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=646"/>
		<updated>2020-11-01T13:37:25Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;strong&amp;gt;MediaWiki has been installed.&amp;lt;/strong&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Consult the [[mediawikiwiki:Special:MyLanguage/Help:Contents|User's Guide]] for information on using the wiki software. Hooray!!! Test!!!! Hmm Hello!!&lt;br /&gt;
&lt;br /&gt;
==Getting started ==&lt;br /&gt;
&lt;br /&gt;
*[[mediawikiwiki:Special:MyLanguage/Manual:Configuration_settings|Configuration settings list]]&lt;br /&gt;
*[[mediawikiwiki:Special:MyLanguage/Manual:FAQ|MediaWiki FAQ]]&lt;br /&gt;
*[https://lists.wikimedia.org/mailman/listinfo/mediawiki-announce MediaWiki release mailing list]&lt;br /&gt;
*[[mediawikiwiki:Special:MyLanguage/Localisation#Translation_resources|Localise MediaWiki for your language]]&lt;br /&gt;
*[[mediawikiwiki:Special:MyLanguage/Manual:Combating_spam|Learn how to combat spam on your wiki]]&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=645</id>
		<title>Main Page</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=645"/>
		<updated>2020-11-01T13:37:01Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: Protected &amp;quot;Main Page&amp;quot; ([Edit=Allow only administrators] (indefinite) [Move=Allow only administrators] (indefinite))&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;strong&amp;gt;MediaWiki has been installed.&amp;lt;/strong&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Consult the [[mediawikiwiki:Special:MyLanguage/Help:Contents|User's Guide]] for information on using the wiki software. Hooray!!! Test!!!! Hmm Hello&lt;br /&gt;
&lt;br /&gt;
==Getting started ==&lt;br /&gt;
&lt;br /&gt;
*[[mediawikiwiki:Special:MyLanguage/Manual:Configuration_settings|Configuration settings list]]&lt;br /&gt;
*[[mediawikiwiki:Special:MyLanguage/Manual:FAQ|MediaWiki FAQ]]&lt;br /&gt;
*[https://lists.wikimedia.org/mailman/listinfo/mediawiki-announce MediaWiki release mailing list]&lt;br /&gt;
*[[mediawikiwiki:Special:MyLanguage/Localisation#Translation_resources|Localise MediaWiki for your language]]&lt;br /&gt;
*[[mediawikiwiki:Special:MyLanguage/Manual:Combating_spam|Learn how to combat spam on your wiki]]&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Test2&amp;diff=636</id>
		<title>Test2</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Test2&amp;diff=636"/>
		<updated>2020-10-31T01:47:43Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This seems to work.&lt;br /&gt;
&lt;br /&gt;
This is a test. Wow.&lt;br /&gt;
&lt;br /&gt;
Hmm&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=632</id>
		<title>Main Page</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=632"/>
		<updated>2020-10-31T01:42:37Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;strong&amp;gt;MediaWiki has been installed.&amp;lt;/strong&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Consult the [[mediawikiwiki:Special:MyLanguage/Help:Contents|User's Guide]] for information on using the wiki software. Hooray!!! Test!!!! Hmm Hello&lt;br /&gt;
&lt;br /&gt;
==Getting started ==&lt;br /&gt;
&lt;br /&gt;
*[[mediawikiwiki:Special:MyLanguage/Manual:Configuration_settings|Configuration settings list]]&lt;br /&gt;
*[[mediawikiwiki:Special:MyLanguage/Manual:FAQ|MediaWiki FAQ]]&lt;br /&gt;
*[https://lists.wikimedia.org/mailman/listinfo/mediawiki-announce MediaWiki release mailing list]&lt;br /&gt;
*[[mediawikiwiki:Special:MyLanguage/Localisation#Translation_resources|Localise MediaWiki for your language]]&lt;br /&gt;
*[[mediawikiwiki:Special:MyLanguage/Manual:Combating_spam|Learn how to combat spam on your wiki]]&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=631</id>
		<title>Main Page</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=631"/>
		<updated>2020-10-29T11:44:59Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;strong&amp;gt;MediaWiki has been installed.&amp;lt;/strong&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Consult the [[mediawikiwiki:Special:MyLanguage/Help:Contents|User's Guide]] for information on using the wiki software. Hooray!!! Test!!!! Hmm&lt;br /&gt;
&lt;br /&gt;
==Getting started ==&lt;br /&gt;
&lt;br /&gt;
*[[mediawikiwiki:Special:MyLanguage/Manual:Configuration_settings|Configuration settings list]]&lt;br /&gt;
*[[mediawikiwiki:Special:MyLanguage/Manual:FAQ|MediaWiki FAQ]]&lt;br /&gt;
*[https://lists.wikimedia.org/mailman/listinfo/mediawiki-announce MediaWiki release mailing list]&lt;br /&gt;
*[[mediawikiwiki:Special:MyLanguage/Localisation#Translation_resources|Localise MediaWiki for your language]]&lt;br /&gt;
*[[mediawikiwiki:Special:MyLanguage/Manual:Combating_spam|Learn how to combat spam on your wiki]]&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=630</id>
		<title>Main Page</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=630"/>
		<updated>2020-10-29T11:44:01Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;strong&amp;gt;MediaWiki has been installed.&amp;lt;/strong&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Consult the [[mediawikiwiki:Special:MyLanguage/Help:Contents|User's Guide]] for information on using the wiki software. Hooray!!! Test!!!!&lt;br /&gt;
&lt;br /&gt;
==Getting started==&lt;br /&gt;
&lt;br /&gt;
*[[mediawikiwiki:Special:MyLanguage/Manual:Configuration_settings|Configuration settings list]]&lt;br /&gt;
*[[mediawikiwiki:Special:MyLanguage/Manual:FAQ|MediaWiki FAQ]]&lt;br /&gt;
*[https://lists.wikimedia.org/mailman/listinfo/mediawiki-announce MediaWiki release mailing list]&lt;br /&gt;
*[[mediawikiwiki:Special:MyLanguage/Localisation#Translation_resources|Localise MediaWiki for your language]]&lt;br /&gt;
*[[mediawikiwiki:Special:MyLanguage/Manual:Combating_spam|Learn how to combat spam on your wiki]]&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Test2&amp;diff=629</id>
		<title>Test2</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Test2&amp;diff=629"/>
		<updated>2020-10-29T11:34:11Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a test. Hooray!!!&amp;lt;ref&amp;gt;{{Cite journal|last=Rishel|first=Chris A.|last2=Zhang|first2=Yuting|last3=Sun|first3=Eric C.|date=2020-10-01|title=Association Between Preoperative Benzodiazepine Use and Postoperative Opioid Use and Health Care Costs|url=https://pubmed.ncbi.nlm.nih.gov/33107919|journal=JAMA network open|volume=3|issue=10|pages=e2018761|doi=10.1001/jamanetworkopen.2020.18761|issn=2574-3805|pmid=33107919}}&amp;lt;/ref&amp;gt;&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Module:Citation/CS1/Configuration&amp;diff=628</id>
		<title>Module:Citation/CS1/Configuration</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Module:Citation/CS1/Configuration&amp;diff=628"/>
		<updated>2020-10-29T11:33:24Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
--[[--------------------------&amp;lt; U N C A T E G O R I Z E D _ N A M E S P A C E S &amp;gt;------------------------------&lt;br /&gt;
&lt;br /&gt;
List of namespaces that should not be included in citation error categories.  Same as setting notracking = true by default&lt;br /&gt;
&lt;br /&gt;
Note: Namespace names should use underscores instead of spaces.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local uncategorized_namespaces = { 'User', 'Talk', 'User_talk', 'Wikipedia_talk', 'File_talk', 'Template_talk', 'Help_talk', 'Category_talk', 'Portal_talk', 'Book_talk', 'Draft_talk', 'Education_Program_talk', 'Module_talk', 'MediaWiki_talk' };&lt;br /&gt;
local uncategorized_subpages = {'/[Ss]andbox', '/[Tt]estcases'};				-- list of Lua patterns found in page names of pages we should not categorize&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; M E S S A G E S &amp;gt;--------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Translation table&lt;br /&gt;
&lt;br /&gt;
The following contains fixed text that may be output as part of a citation.&lt;br /&gt;
This is separated from the main body to aid in future translations of this&lt;br /&gt;
module.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local messages = {&lt;br /&gt;
	['agency'] = '$1 $2',														-- $1 is sepc, $2 is agency&lt;br /&gt;
	['archived-dead'] = 'Archived from $1 on $2',&lt;br /&gt;
	['archived-live'] = '$1 from the original on $2',&lt;br /&gt;
	['archived-missing'] = 'Archived from the original$1 on $2',&lt;br /&gt;
	['archived-unfit'] = 'Archived from the original on ',&lt;br /&gt;
	['archived'] = 'Archived',&lt;br /&gt;
	['by'] = 'By',																-- contributions to authored works: introduction, foreword, afterword&lt;br /&gt;
	['cartography'] = 'Cartography by $1',&lt;br /&gt;
	['editor'] = 'ed.',&lt;br /&gt;
	['editors'] = 'eds.',&lt;br /&gt;
	['edition'] = '($1 ed.)',&lt;br /&gt;
	['episode'] = 'Episode $1',&lt;br /&gt;
	['et al'] = 'et al.',&lt;br /&gt;
	['in'] = 'In',																-- edited works&lt;br /&gt;
	['inactive'] = 'inactive',&lt;br /&gt;
	['inset'] = '$1 inset',&lt;br /&gt;
	['interview'] = 'Interviewed by $1',										&lt;br /&gt;
	['lay summary'] = 'Lay summary',&lt;br /&gt;
	['newsgroup'] = '[[Usenet newsgroup|Newsgroup]]:&amp;amp;nbsp;$1',&lt;br /&gt;
--	['nodate'] = 'n.d.', -- in the future for |date=none|n.d.|nd&lt;br /&gt;
	['notitle'] = 'No title', -- for |title=(()) and (in the future) |title=none&lt;br /&gt;
	['original'] = 'the original',&lt;br /&gt;
	['origdate'] = ' [$1]',&lt;br /&gt;
	['published'] = ' (published $1)',&lt;br /&gt;
	['retrieved'] = 'Retrieved $1',&lt;br /&gt;
	['season'] = 'Season $1',&lt;br /&gt;
	['section'] = '§ $1',&lt;br /&gt;
	['sections'] = '§§ $1',&lt;br /&gt;
	['series'] = '$1 $2',														-- $1 is sepc, $2 is series&lt;br /&gt;
	['seriesnum'] = 'Series $1',&lt;br /&gt;
	['translated'] = 'Translated by $1',&lt;br /&gt;
	['type'] = ' ($1)',															-- for titletype&lt;br /&gt;
	['written'] = 'Written at $1',&lt;br /&gt;
&lt;br /&gt;
	['vol'] = '$1 Vol.&amp;amp;nbsp;$2',												-- $1 is sepc; bold journal style volume is in presentation{}&lt;br /&gt;
	['vol-no'] = '$1 Vol.&amp;amp;nbsp;$2 no.&amp;amp;nbsp;$3',									-- sepc, volume, issue&lt;br /&gt;
	['issue'] = '$1 No.&amp;amp;nbsp;$2',												-- $1 is sepc&lt;br /&gt;
&lt;br /&gt;
	['j-vol'] = '$1 $2',														-- sepc, volume; bold journal volume is in presentation{}&lt;br /&gt;
	['j-issue'] = ' ($1)',&lt;br /&gt;
&lt;br /&gt;
	['nopp'] = '$1 $2';															-- page(s) without prefix; $1 is sepc&lt;br /&gt;
&lt;br /&gt;
	['p-prefix'] = &amp;quot;$1 p.&amp;amp;nbsp;$2&amp;quot;,												-- $1 is sepc&lt;br /&gt;
	['pp-prefix'] = &amp;quot;$1 pp.&amp;amp;nbsp;$2&amp;quot;,											-- $1 is sepc&lt;br /&gt;
	['j-page(s)'] = ': $1',														-- same for page and pages&lt;br /&gt;
&lt;br /&gt;
	['sheet'] = '$1 Sheet&amp;amp;nbsp;$2',												-- $1 is sepc&lt;br /&gt;
	['sheets'] = '$1 Sheets&amp;amp;nbsp;$2',											-- $1 is sepc&lt;br /&gt;
	['j-sheet'] = ': Sheet&amp;amp;nbsp;$1',&lt;br /&gt;
	['j-sheets'] = ': Sheets&amp;amp;nbsp;$1',&lt;br /&gt;
	&lt;br /&gt;
	['language'] = '(in $1)',&lt;br /&gt;
	['via'] = &amp;quot; &amp;amp;ndash; via $1&amp;quot;,&lt;br /&gt;
	['event'] = 'Event occurs at',&lt;br /&gt;
	['minutes'] = 'minutes in',&lt;br /&gt;
	&lt;br /&gt;
	-- Determines the location of the help page&lt;br /&gt;
	['help page link'] = 'Help:CS1 errors',&lt;br /&gt;
	['help page label'] = 'help',&lt;br /&gt;
	&lt;br /&gt;
	-- Internal errors (should only occur if configuration is bad)&lt;br /&gt;
	['undefined_error'] = 'Called with an undefined error condition',&lt;br /&gt;
	['unknown_manual_ID'] = 'Unrecognized manual ID mode',&lt;br /&gt;
	['unknown_ID_mode'] = 'Unrecognized ID mode',&lt;br /&gt;
	['unknown_argument_map'] = 'Argument map not defined for this variable',&lt;br /&gt;
	['bare_url_no_origin'] = 'Bare URL found but origin indicator is nil or empty',&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[=[-------------------------&amp;lt; E T _ A L _ P A T T E R N S &amp;gt;--------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
This table provides Lua patterns for the phrase &amp;quot;et al&amp;quot; and variants in name text&lt;br /&gt;
(author, editor, etc.). The main module uses these to identify and emit the 'etal' message.&lt;br /&gt;
&lt;br /&gt;
]=]&lt;br /&gt;
&lt;br /&gt;
local et_al_patterns = {&lt;br /&gt;
	&amp;quot;[;,]? *[\&amp;quot;']*%f[%a][Ee][Tt]%.? *[Aa][Ll][%.\&amp;quot;']*$&amp;quot;,						-- variations on the 'et al' theme&lt;br /&gt;
	&amp;quot;[;,]? *[\&amp;quot;']*%f[%a][Ee][Tt]%.? *[Aa][Ll][Ii][Aa][%.\&amp;quot;']*$&amp;quot;,				-- variations on the 'et alia' theme&lt;br /&gt;
	&amp;quot;[;,]? *%f[%a]and [Oo]thers&amp;quot;,												-- and alternate to et al.&lt;br /&gt;
	&amp;quot;%[%[ *[Ee][Tt]%.? *[Aa][Ll]%.? *%]%]&amp;quot;,										-- a wikilinked form&lt;br /&gt;
	&amp;quot;[%(%[] *[Ee][Tt]%.? *[Aa][Ll]%.? *[%)%]]&amp;quot;,									-- a bracketed form&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; E D I T O R _ M A R K U P _ P A T T E R N S &amp;gt;----------------------------------&lt;br /&gt;
&lt;br /&gt;
This table provides Lua patterns for the phrase &amp;quot;ed&amp;quot; and variants in name text&lt;br /&gt;
(author, editor, etc.). The main module uses these to identify and emit the&lt;br /&gt;
'extra_text_names' message. (It is not the only series of patterns for this message.)&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
local editor_markup_patterns = {												-- these patterns match annotations at end of name&lt;br /&gt;
	'%f[%(%[][%(%[]%s*[Ee][Dd][Ss]?%.?%s*[%)%]]?$',								-- (ed) or (eds): leading '(', case insensitive 'ed', optional 's', '.' and/or ')'&lt;br /&gt;
	'[,%.%s]%f[e]eds?%.?$',														-- ed or eds: without '('or ')'; case sensitive (ED could be initials Ed could be name)&lt;br /&gt;
	'%f[%(%[][%(%[]%s*[Ee][Dd][Ii][Tt][Oo][Rr][Ss]?%.?%s*[%)%]]?$',				-- (editor) or (editors): leading '(', case insensitive, optional '.' and/or ')'&lt;br /&gt;
	'[,%.%s]%f[Ee][Dd][Ii][Tt][Oo][Rr][Ss]?%.?$',								-- editor or editors: without '('or ')'; case insensitive&lt;br /&gt;
		&lt;br /&gt;
																				-- these patterns match annotations at beginning of name&lt;br /&gt;
	'^eds?[%.,;]',																-- ed. or eds.: lower case only, optional 's', requires '.'&lt;br /&gt;
	'^[%(%[]%s*[Ee][Dd][Ss]?%.?%s*[%)%]]',										-- (ed) or (eds): also sqare brackets, case insensitive, optional 's', '.'&lt;br /&gt;
	'^[%(%[]?%s*[Ee][Dd][Ii][Tt][Oo][Rr][Ss]?%A',								-- (editor or (editors: also square brackets, case insensitive, optional brackets, 's'&lt;br /&gt;
	'^[%(%[]?%s*[Ee][Dd][Ii][Tt][Ee][Dd]%A',									-- (edited: also square brackets, case insensitive, optional brackets&lt;br /&gt;
&lt;br /&gt;
																				-- these patterns match annotations that are the 'name'	&lt;br /&gt;
	'^[Ee][Dd][Ii][Tt][Oo][Rr][Ss]?%.?$',										-- editor or editors; case insensitive&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; P R E S E N T A T I O N &amp;gt;------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Fixed presentation markup.  Originally part of citation_config.messages it has been moved into its own, more semantically&lt;br /&gt;
correct place.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local presentation = &lt;br /&gt;
	{&lt;br /&gt;
	-- Error output&lt;br /&gt;
	-- .error class is specified at https://git.wikimedia.org/blob/mediawiki%2Fcore.git/9553bd02a5595da05c184f7521721fb1b79b3935/skins%2Fcommon%2Fshared.css#L538&lt;br /&gt;
	-- .citation-comment class is specified at Help:CS1_errors#Controlling_error_message_display&lt;br /&gt;
	['hidden-error'] = '&amp;lt;span class=&amp;quot;cs1-hidden-error error citation-comment&amp;quot;&amp;gt;$1&amp;lt;/span&amp;gt;',&lt;br /&gt;
	['visible-error'] = '&amp;lt;span class=&amp;quot;cs1-visible-error error citation-comment&amp;quot;&amp;gt;$1&amp;lt;/span&amp;gt;',&lt;br /&gt;
	['hidden-maint'] = '&amp;lt;span class=&amp;quot;cs1-maint citation-comment&amp;quot;&amp;gt;$1&amp;lt;/span&amp;gt;',&lt;br /&gt;
	&lt;br /&gt;
	['accessdate'] = '&amp;lt;span class=&amp;quot;reference-accessdate&amp;quot;&amp;gt;$1$2&amp;lt;/span&amp;gt;',			-- to allow editors to hide accessdate using personal CSS&lt;br /&gt;
&lt;br /&gt;
	['bdi'] = '&amp;lt;bdi$1&amp;gt;$2&amp;lt;/bdi&amp;gt;',												-- bidirectional isolation used with |script-title= and the like&lt;br /&gt;
&lt;br /&gt;
	['cite'] = '&amp;lt;cite class=&amp;quot;$1&amp;quot;&amp;gt;$2&amp;lt;/cite&amp;gt;';									-- |ref= not set so no id=&amp;quot;...&amp;quot; attribute&lt;br /&gt;
	['cite-id'] = '&amp;lt;cite id=&amp;quot;$1&amp;quot; class=&amp;quot;$2&amp;quot;&amp;gt;$3&amp;lt;/cite&amp;gt;';							-- for use when |ref= is set&lt;br /&gt;
&lt;br /&gt;
	['format'] = ' &amp;lt;span class=&amp;quot;cs1-format&amp;quot;&amp;gt;($1)&amp;lt;/span&amp;gt;',						-- for |format=, |chapter-format=, etc.&lt;br /&gt;
	&lt;br /&gt;
																				-- various access levels, for |access=, |doi-access=, |arxiv=, ...&lt;br /&gt;
																				-- narrow no-break space &amp;amp;#8239; may work better than nowrap CSS. Or not? Browser support?&lt;br /&gt;
&lt;br /&gt;
	['ext-link-access-signal'] = '&amp;lt;span class=&amp;quot;$1&amp;quot; title=&amp;quot;$2&amp;quot;&amp;gt;$3&amp;lt;/span&amp;gt;',		-- external link with appropriate lock icon&lt;br /&gt;
		['free'] = {class='cs1-lock-free', title='Freely accessible'},			-- classes defined in Module:Citation/CS1/styles.css&lt;br /&gt;
		['registration'] = {class='cs1-lock-registration', title='Free registration required'},&lt;br /&gt;
		['limited'] = {class='cs1-lock-limited', title='Free access subject to limited trial, subscription normally required'},&lt;br /&gt;
		['subscription'] = {class='cs1-lock-subscription', title='Paid subscription required'},&lt;br /&gt;
&lt;br /&gt;
	['interwiki-icon'] = '&amp;lt;span class=&amp;quot;$1&amp;quot; title=&amp;quot;$2&amp;quot;&amp;gt;$3&amp;lt;/span&amp;gt;',&lt;br /&gt;
		['class-wikisource'] = 'cs1-ws-icon',&lt;br /&gt;
&lt;br /&gt;
	['italic-title'] = &amp;quot;''$1''&amp;quot;,&lt;br /&gt;
&lt;br /&gt;
	['kern-left'] = '&amp;lt;span class=&amp;quot;cs1-kern-left&amp;quot;&amp;gt;$1&amp;lt;/span&amp;gt;$2',					-- spacing to use when title contains leading single or double quote mark&lt;br /&gt;
	['kern-right'] = '$1&amp;lt;span class=&amp;quot;cs1-kern-right&amp;quot;&amp;gt;$2&amp;lt;/span&amp;gt;',				-- spacing to use when title contains trailing single or double quote mark&lt;br /&gt;
&lt;br /&gt;
																				-- these for simple wikilinked titles [[&amp;quot;text]], [[text&amp;quot;]] and [[&amp;quot;text&amp;quot;]]&lt;br /&gt;
																				-- span wraps entire wikilink&lt;br /&gt;
	['kern-wl-left'] = '&amp;lt;span class=&amp;quot;cs1-kern-wl-left&amp;quot;&amp;gt;$1&amp;lt;/span&amp;gt;',				-- when title contains leading single or double quote mark&lt;br /&gt;
	['kern-wl-right'] = '&amp;lt;span class=&amp;quot;cs1-kern-wl-left&amp;quot;&amp;gt;$1&amp;lt;/span&amp;gt;',				-- when title contains trailing single or double quote mark&lt;br /&gt;
	['kern-wl-both'] = '&amp;lt;span class=&amp;quot;cs1-kern-wl-left cs1-kern-wl-right&amp;quot;&amp;gt;$1&amp;lt;/span&amp;gt;',	-- when title contains leading and trailing single or double quote marks&lt;br /&gt;
&lt;br /&gt;
	['nowrap1'] = '&amp;lt;span class=&amp;quot;nowrap&amp;quot;&amp;gt;$1&amp;lt;/span&amp;gt;',								-- for nowrapping an item: &amp;lt;span ...&amp;gt;yyyy-mm-dd&amp;lt;/span&amp;gt;&lt;br /&gt;
	['nowrap2'] = '&amp;lt;span class=&amp;quot;nowrap&amp;quot;&amp;gt;$1&amp;lt;/span&amp;gt; $2',							-- for nowrapping portions of an item: &amp;lt;span ...&amp;gt;dd mmmm&amp;lt;/span&amp;gt; yyyy (note white space)&lt;br /&gt;
&lt;br /&gt;
	['ocins'] = '&amp;lt;span title=&amp;quot;$1&amp;quot; class=&amp;quot;Z3988&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;',&lt;br /&gt;
	&lt;br /&gt;
	['parameter'] = '&amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;$1=&amp;lt;/code&amp;gt;',&lt;br /&gt;
 &lt;br /&gt;
	['ps_cs1'] = '.';															-- CS1 style postscript (terminal) character&lt;br /&gt;
	['ps_cs2'] = '';															-- CS2 style postscript (terminal) character (empty string)&lt;br /&gt;
&lt;br /&gt;
	['quoted-text'] = '&amp;lt;q&amp;gt;$1&amp;lt;/q&amp;gt;',												-- for wrapping |quote= content&lt;br /&gt;
	['quoted-title'] = '&amp;quot;$1&amp;quot;',&lt;br /&gt;
&lt;br /&gt;
	['sep_cs1'] = '.',															-- CS1 element separator&lt;br /&gt;
	['sep_cs2'] = ',',															-- CS2 separator&lt;br /&gt;
	['sep_nl'] = ';',															-- CS1|2 style name-list separator between names is a semicolon&lt;br /&gt;
	['sep_nl_and'] = ' and ',													-- used as last nl sep when |name-list-style=and and list has 2 items&lt;br /&gt;
	['sep_nl_end'] = '; and ',													-- used as last nl sep when |name-list-style=and and list has 3+ names&lt;br /&gt;
	['sep_name'] = ', ',														-- CS1|2 style last/first separator is &amp;lt;comma&amp;gt;&amp;lt;space&amp;gt;&lt;br /&gt;
	['sep_nl_vanc'] = ',',														-- Vancouver style name-list separator between authors is a comma&lt;br /&gt;
	['sep_name_vanc'] = ' ',													-- Vancouver style last/first separator is a space&lt;br /&gt;
&lt;br /&gt;
	['sep_list'] = ', ',														-- used for |language= when list has 3+ items except for last sep which uses sep_list_end&lt;br /&gt;
	['sep_list_pair'] = ' and ',												-- used for |language= when list has 2 items&lt;br /&gt;
	['sep_list_end'] = ', and ',												-- used as last list sep for |language= when list has 3+ items&lt;br /&gt;
	&lt;br /&gt;
	['trans-italic-title'] = &amp;quot;&amp;amp;#91;''$1''&amp;amp;#93;&amp;quot;,&lt;br /&gt;
	['trans-quoted-title'] = &amp;quot;&amp;amp;#91;$1&amp;amp;#93;&amp;quot;, -- for |trans-title= and |trans-quote=&lt;br /&gt;
	['vol-bold'] = '$1 &amp;lt;b&amp;gt;$2&amp;lt;/b&amp;gt;',												-- sepc, volume; for bold journal cites; for other cites ['vol'] in messages{}&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
	&lt;br /&gt;
--[[--------------------------&amp;lt; A L I A S E S &amp;gt;----------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Aliases table for commonly passed parameters.&lt;br /&gt;
&lt;br /&gt;
Parameter names on the right side in the assignements in this table must have been defined in the Whitelist&lt;br /&gt;
before they will be recognized as valid parameter names&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local aliases = {&lt;br /&gt;
	['AccessDate'] = {'access-date', 'accessdate'},								-- Used by InternetArchiveBot&lt;br /&gt;
	['Agency'] = 'agency',&lt;br /&gt;
	['ArchiveDate'] = {'archive-date', 'archivedate'},							-- Used by InternetArchiveBot&lt;br /&gt;
	['ArchiveFormat'] = 'archive-format',&lt;br /&gt;
	['ArchiveURL'] = {'archive-url', 'archiveurl'},								-- Used by InternetArchiveBot&lt;br /&gt;
	['ASINTLD'] = 'asin-tld',&lt;br /&gt;
	['At'] = 'at',																-- Used by InternetArchiveBot&lt;br /&gt;
	['Authors'] = {'authors', 'people', 'credits'},&lt;br /&gt;
	['BookTitle'] = {'book-title', 'booktitle'},&lt;br /&gt;
	['Cartography'] = 'cartography',&lt;br /&gt;
	['Chapter'] = {'chapter', 'contribution', 'entry', 'article', 'section'},&lt;br /&gt;
	['ChapterFormat'] = {'chapter-format', 'contribution-format', 'entry-format', 'article-format', 'section-format'};&lt;br /&gt;
	['ChapterURL'] = {'chapter-url', 'contribution-url', 'entry-url', 'article-url', 'section-url', 'chapterurl', 'contributionurl', 'sectionurl'},	-- Used by InternetArchiveBot&lt;br /&gt;
	['ChapterUrlAccess'] = {'chapter-url-access', 'contribution-url-access', 'entry-url-access', 'article-url-access', 'section-url-access'},	-- Used by InternetArchiveBot&lt;br /&gt;
	['Class'] = 'class',														-- cite arxiv and arxiv identifiers&lt;br /&gt;
	['Collaboration'] = 'collaboration',&lt;br /&gt;
	['Conference'] = {'conference', 'event'},&lt;br /&gt;
	['ConferenceFormat'] = {'conference-format', 'event-format'},&lt;br /&gt;
	['ConferenceURL'] = {'conference-url', 'event-url', 'conferenceurl', 'eventurl'},	-- Used by InternetArchiveBot&lt;br /&gt;
	['Date'] = {'date', 'air-date', 'airdate'},									-- air-date and airdate for cite episode and cite serial only&lt;br /&gt;
	['Degree'] = 'degree',&lt;br /&gt;
	['DF'] = 'df',&lt;br /&gt;
	['DisplayAuthors'] = {'display-authors', 'display-subjects', 'displayauthors'},&lt;br /&gt;
	['DisplayContributors'] = 'display-contributors',&lt;br /&gt;
	['DisplayEditors'] = 'display-editors',&lt;br /&gt;
	['DisplayInterviewers'] = 'display-interviewers',&lt;br /&gt;
	['DisplayTranslators'] = 'display-translators',&lt;br /&gt;
	['Docket'] = 'docket',&lt;br /&gt;
	['DoiBroken'] = 'doi-broken-date',&lt;br /&gt;
	['Edition'] = 'edition',&lt;br /&gt;
	['Editors'] = 'editors',&lt;br /&gt;
	['Embargo'] = 'pmc-embargo-date',&lt;br /&gt;
	['Encyclopedia'] = {'encyclopedia', 'encyclopaedia', 'dictionary'},			-- cite encyclopedia only&lt;br /&gt;
	['Episode'] = 'episode',													-- cite serial only TODO: make available to cite episode?&lt;br /&gt;
	['Format'] = 'format',&lt;br /&gt;
	['ID'] = {'id', 'ID'},&lt;br /&gt;
	['IgnoreISBN'] = 'ignore-isbn-error',&lt;br /&gt;
	['Inset'] = 'inset',&lt;br /&gt;
	['Issue'] = {'issue', 'number'},&lt;br /&gt;
	['Language'] = {'language', 'lang'},&lt;br /&gt;
	['LastAuthorAmp'] = {'last-author-amp', 'lastauthoramp'},&lt;br /&gt;
	['LayDate'] = {'lay-date', 'laydate'},&lt;br /&gt;
	['LayFormat'] = 'lay-format',&lt;br /&gt;
	['LaySource'] = {'lay-source', 'laysource'},&lt;br /&gt;
	['LayURL'] = {'lay-url', 'layurl'},											-- Used by InternetArchiveBot&lt;br /&gt;
	['MailingList'] = {'mailing-list', 'mailinglist'},							-- cite mailing list only&lt;br /&gt;
	['Map'] = 'map',															-- cite map only&lt;br /&gt;
	['MapFormat'] = 'map-format',												-- cite map only&lt;br /&gt;
	['MapURL'] = {'map-url', 'mapurl'},											-- cite map only -- Used by InternetArchiveBot&lt;br /&gt;
	['MapUrlAccess'] = 'map-url-access',										-- cite map only -- Used by InternetArchiveBot&lt;br /&gt;
	['Minutes'] = 'minutes',&lt;br /&gt;
	['Mode'] = 'mode',&lt;br /&gt;
	['NameListStyle'] = {'name-list-style', 'name-list-format'},&lt;br /&gt;
	['Network'] = 'network',&lt;br /&gt;
	['Newsgroup'] = 'newsgroup',												-- cite newsgroup only&lt;br /&gt;
	['NoPP'] = {'no-pp', 'nopp'},&lt;br /&gt;
	['NoTracking'] = {'no-tracking', 'template-doc-demo', 'nocat'},&lt;br /&gt;
	['Number'] = 'number',														-- this case only for cite techreport&lt;br /&gt;
	['OrigDate'] = {'orig-date', 'orig-year', 'origyear'},&lt;br /&gt;
	['Others'] = 'others',&lt;br /&gt;
	['Page'] = {'page', 'p'},													-- Used by InternetArchiveBot&lt;br /&gt;
	['Pages'] = {'pages', 'pp'},												-- Used by InternetArchiveBot&lt;br /&gt;
	['Periodical'] = {'journal', 'magazine', 'newspaper', 'periodical', 'website', 'work'},&lt;br /&gt;
	['Place'] = {'place', 'location'},&lt;br /&gt;
	['PostScript'] = 'postscript',&lt;br /&gt;
	['PublicationDate'] = {'publication-date', 'publicationdate'},&lt;br /&gt;
	['PublicationPlace'] = {'publication-place', 'publicationplace'},&lt;br /&gt;
	['PublisherName'] = {'publisher', 'institution'},&lt;br /&gt;
	['Quote'] = {'quote', 'quotation'},&lt;br /&gt;
	['QuotePage'] = 'quote-page',&lt;br /&gt;
	['QuotePages'] = 'quote-pages',&lt;br /&gt;
	['Ref'] = 'ref',&lt;br /&gt;
	['Scale'] = 'scale',&lt;br /&gt;
	['ScriptChapter'] = {'script-chapter', 'script-contribution', 'script-entry', 'script-article', 'script-section'},&lt;br /&gt;
	['ScriptMap'] = 'script-map',&lt;br /&gt;
	['ScriptPeriodical'] = {'script-journal', 'script-magazine', 'script-newspaper', 'script-periodical', 'script-website', 'script-work'},&lt;br /&gt;
	['ScriptQuote'] = 'script-quote',&lt;br /&gt;
	['ScriptTitle'] = 'script-title',											-- Used by InternetArchiveBot&lt;br /&gt;
	['Season'] = 'season',&lt;br /&gt;
	['Sections'] = 'sections',													-- cite map only&lt;br /&gt;
	['Series'] = {'series', 'version'},&lt;br /&gt;
	['SeriesLink'] = {'series-link', 'serieslink'},&lt;br /&gt;
	['SeriesNumber'] = {'series-number', 'series-no', 'seriesnumber', 'seriesno'},&lt;br /&gt;
	['Sheet'] = 'sheet',														-- cite map only&lt;br /&gt;
	['Sheets'] = 'sheets',														-- cite map only&lt;br /&gt;
	['Station'] = 'station',&lt;br /&gt;
	['Time'] = 'time',&lt;br /&gt;
	['TimeCaption'] = {'time-caption', 'timecaption'},&lt;br /&gt;
	['Title'] = 'title',														-- Used by InternetArchiveBot&lt;br /&gt;
	['TitleLink'] = {'title-link', 'episode-link', 'titlelink', 'episodelink'},	-- Used by InternetArchiveBot&lt;br /&gt;
	['TitleNote'] = 'department',&lt;br /&gt;
	['TitleType'] = {'type', 'medium'},&lt;br /&gt;
	['TransChapter'] = {'trans-article', 'trans-chapter', 'trans-contribution', 'trans-entry', 'trans-section'},&lt;br /&gt;
	['Transcript'] = 'transcript',&lt;br /&gt;
	['TranscriptFormat'] = 'transcript-format',	&lt;br /&gt;
	['TranscriptURL'] = {'transcript-url', 'transcripturl'},					-- Used by InternetArchiveBot&lt;br /&gt;
	['TransMap'] = 'trans-map',													-- cite map only&lt;br /&gt;
	['TransPeriodical'] = {'trans-journal', 'trans-magazine', 'trans-newspaper', 'trans-periodical', 'trans-website', 'trans-work'},&lt;br /&gt;
	['TransQuote'] = 'trans-quote',&lt;br /&gt;
	['TransTitle'] = 'trans-title',												-- Used by InternetArchiveBot&lt;br /&gt;
	['URL'] = {'url', 'URL'},													-- Used by InternetArchiveBot&lt;br /&gt;
	['UrlAccess'] = 'url-access',												-- Used by InternetArchiveBot&lt;br /&gt;
	['UrlStatus'] = 'url-status',												-- Used by InternetArchiveBot&lt;br /&gt;
	['Vauthors'] = 'vauthors',&lt;br /&gt;
	['Veditors'] = 'veditors',&lt;br /&gt;
	['Via'] = 'via',&lt;br /&gt;
	['Volume'] = 'volume',&lt;br /&gt;
	['Year'] = 'year',&lt;br /&gt;
&lt;br /&gt;
	['AuthorList-First'] = {&amp;quot;first#&amp;quot;, &amp;quot;author-first#&amp;quot;, &amp;quot;author#-first&amp;quot;, &amp;quot;given#&amp;quot;, &amp;quot;author-given#&amp;quot;, &amp;quot;author#-given&amp;quot;},&lt;br /&gt;
	['AuthorList-Last'] = {&amp;quot;last#&amp;quot;, &amp;quot;author-last#&amp;quot;, &amp;quot;author#-last&amp;quot;, &amp;quot;surname#&amp;quot;, &amp;quot;author-surname#&amp;quot;, &amp;quot;author#-surname&amp;quot;, &amp;quot;author#&amp;quot;, &amp;quot;subject#&amp;quot;, 'host#'},&lt;br /&gt;
	['AuthorList-Link'] = {&amp;quot;author-link#&amp;quot;, &amp;quot;author#-link&amp;quot;, &amp;quot;subject-link#&amp;quot;, &amp;quot;subject#-link&amp;quot;, &amp;quot;authorlink#&amp;quot;, &amp;quot;author#link&amp;quot;, &amp;quot;subjectlink#&amp;quot;, &amp;quot;subject#link&amp;quot;},&lt;br /&gt;
	['AuthorList-Mask'] = {&amp;quot;author-mask#&amp;quot;, &amp;quot;author#-mask&amp;quot;, &amp;quot;subject-mask#&amp;quot;, &amp;quot;subject#-mask&amp;quot;, &amp;quot;authormask#&amp;quot;, &amp;quot;author#mask&amp;quot;},&lt;br /&gt;
&lt;br /&gt;
	['ContributorList-First'] = {'contributor-first#', 'contributor#-first', 'contributor-given#', 'contributor#-given'},&lt;br /&gt;
	['ContributorList-Last'] = {'contributor-last#', 'contributor#-last', 'contributor-surname#', 'contributor#-surname', 'contributor#'},&lt;br /&gt;
	['ContributorList-Link'] = {'contributor-link#', 'contributor#-link'},&lt;br /&gt;
	['ContributorList-Mask'] = {'contributor-mask#', 'contributor#-mask'},&lt;br /&gt;
&lt;br /&gt;
	['EditorList-First'] = {&amp;quot;editor-first#&amp;quot;, &amp;quot;editor#-first&amp;quot;, &amp;quot;editor-given#&amp;quot;, &amp;quot;editor#-given&amp;quot;},&lt;br /&gt;
	['EditorList-Last'] = {&amp;quot;editor-last#&amp;quot;, &amp;quot;editor#-last&amp;quot;, &amp;quot;editor-surname#&amp;quot;, &amp;quot;editor#-surname&amp;quot;, &amp;quot;editor#&amp;quot;},&lt;br /&gt;
	['EditorList-Link'] = {&amp;quot;editor-link#&amp;quot;, &amp;quot;editor#-link&amp;quot;, &amp;quot;editorlink#&amp;quot;, &amp;quot;editor#link&amp;quot;}, -- unhyphenated forms to be deprecated&lt;br /&gt;
	['EditorList-Mask'] = {&amp;quot;editor-mask#&amp;quot;, &amp;quot;editor#-mask&amp;quot;},&lt;br /&gt;
	&lt;br /&gt;
	['InterviewerList-First'] = {'interviewer-first#', 'interviewer#-first', 'interviewer-given#', 'interviewer#-given'},&lt;br /&gt;
	['InterviewerList-Last'] = {'interviewer-last#', 'interviewer#-last', 'interviewer-surname#', 'interviewer#-surname', 'interviewer#'},&lt;br /&gt;
	['InterviewerList-Link'] = {'interviewer-link#', 'interviewer#-link'},&lt;br /&gt;
	['InterviewerList-Mask'] = {'interviewer-mask#', 'interviewer#-mask'},&lt;br /&gt;
&lt;br /&gt;
	['TranslatorList-First'] = {'translator-first#', 'translator#-first', 'translator-given#', 'translator#-given'},&lt;br /&gt;
	['TranslatorList-Last'] = {'translator-last#', 'translator#-last', 'translator-surname#', 'translator#-surname', 'translator#'},&lt;br /&gt;
	['TranslatorList-Link'] = {'translator-link#', 'translator#-link'},&lt;br /&gt;
	['TranslatorList-Mask'] = {'translator-mask#', 'translator#-mask'},&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; P U N C T _ S K I P &amp;gt;----------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
builds a table of parameter names that the extraneous terminal punctuation check should not check.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local punct_skip = {};&lt;br /&gt;
&lt;br /&gt;
local meta_params = {															-- table of aliases[] keys (meta parameters); each key has a table of parameter names for a value&lt;br /&gt;
	'BookTitle', 'Chapter', 'ScriptChapter', 'ScriptTitle', 'Title', 'TransChapter', 'Transcript', 'TransMap',	'TransTitle',	-- title-holding parameters&lt;br /&gt;
	'AuthorList-Mask', 'ContributorList-Mask', 'EditorList-Mask', 'InterviewerList-Mask', 'TranslatorList-Mask',	-- name-list mask may have name separators&lt;br /&gt;
	'PostScript', 'Quote', 'ScriptQuote', 'TransQuote', 'Ref',																		-- miscellaneous&lt;br /&gt;
	'ArchiveURL', 'ChapterURL', 'ConferenceURL', 'LayURL', 'MapURL', 'TranscriptURL', 'URL',			-- url-holding parameters&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
	for _, meta_param in ipairs (meta_params) do								-- for each meta parameter key&lt;br /&gt;
		local params = aliases[meta_param];										-- get the parameter or the table of parameters associated with the meta parameter name&lt;br /&gt;
		if 'string' == type (params) then&lt;br /&gt;
			punct_skip[params] = 1;												-- just a single parameter&lt;br /&gt;
		else&lt;br /&gt;
			for _, param in ipairs (params) do									-- get the parameter name&lt;br /&gt;
				punct_skip[param] = 1;											-- add the parameter name to the skip table&lt;br /&gt;
				local count;&lt;br /&gt;
				param, count = param:gsub ('#', '');							-- remove enumerator marker from enumerated parameters&lt;br /&gt;
				if 0 ~= count then												-- if removed&lt;br /&gt;
					punct_skip[param] = 1;										-- add param name without enumerator marker&lt;br /&gt;
				end&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; S P E C I A L   C A S E   T R A N S L A T I O N S &amp;gt;----------------------------&lt;br /&gt;
&lt;br /&gt;
This table is primarily here to support internationalization.  Translations in this table are used, for example,&lt;br /&gt;
when an error message, category name, etc., is extracted from the English alias key.  There may be other cases where&lt;br /&gt;
this translation table may be useful.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local special_case_translation = {&lt;br /&gt;
	['AuthorList'] = 'authors list',											-- used to assemble maintenance category names&lt;br /&gt;
	['ContributorList'] = 'contributors list',									-- translation of these names plus translation of the base mainenance category names in maint_cats{} table below&lt;br /&gt;
	['EditorList'] = 'editors list',											-- must match the names of the actual categories&lt;br /&gt;
	['InterviewerList'] = 'interviewers list',									-- this group or translations used by name_has_ed_markup() and name_has_mult_names()&lt;br /&gt;
	['TranslatorList'] = 'translators list',&lt;br /&gt;
	&lt;br /&gt;
	['authors'] = 'authors',													-- used to assemble maintenance category names&lt;br /&gt;
	['contributors'] = 'contributors',											-- translation of these names plus translation of the base maintenance category names in maint_cats{} table below&lt;br /&gt;
	['editors'] = 'editors',													-- must match the names of the actual categories&lt;br /&gt;
	['interviewers'] = 'interviewers',											-- this group of translations used by get_display_names()&lt;br /&gt;
	['translators'] = 'translators',&lt;br /&gt;
&lt;br /&gt;
																				-- Lua patterns to match pseudo-titles used by Internet Archive bot and others as place holder for unknown |title= value&lt;br /&gt;
	['archived_copy'] = {														-- used with CS1 maint: Archive[d] copy as title&lt;br /&gt;
		['en'] = '^archived?%s+copy$',											-- for English; translators: keep this because templates imported from en.wiki&lt;br /&gt;
		['local'] = nil,														-- translators: replace ['local'] = nil with lowercase translation only when bots or tools create generic titles in your language&lt;br /&gt;
		},&lt;br /&gt;
&lt;br /&gt;
																				-- Lua patterns to match generic titles; usually created by bots of reference filling tools&lt;br /&gt;
																				-- translators: replace ['local'] = nil with lowercase translation only when bots or tools create generic titles in your language&lt;br /&gt;
	['generic_titles'] = {&lt;br /&gt;
		{&lt;br /&gt;
		['en'] = {'^wayback%s+machine$', false},								-- patterns in this table to be lowercase only&lt;br /&gt;
		['local'] = nil,														-- leave this nil except when there is a matching generic title in your language&lt;br /&gt;
		},&lt;br /&gt;
		{['en'] = {'are you a robot', true},				['local'] = nil},&lt;br /&gt;
		{['en'] = {'hugedomains.com', true},				['local'] = nil},&lt;br /&gt;
		{['en'] = {'^[%(%[{&amp;lt;]?no +title[&amp;gt;}%]%)]?$', false},	['local'] = nil},&lt;br /&gt;
		{['en'] = {'page not found', true},					['local'] = nil},&lt;br /&gt;
		{['en'] = {'^[%(%[{&amp;lt;]?unknown[&amp;gt;}%]%)]?$', false},	['local'] = nil},&lt;br /&gt;
		{['en'] = {'website is for sale', true},			['local'] = nil},&lt;br /&gt;
		{['en'] = {'^404', true},							['local'] = nil},&lt;br /&gt;
		}&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; D A T E _ N A M E S &amp;gt;----------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
This table of tables lists local language date names and fallback English date names.  The code in Date_validation&lt;br /&gt;
will look first in the local table for valid date names.  If date names are not found in the local table, the code&lt;br /&gt;
will look in the English table.&lt;br /&gt;
&lt;br /&gt;
Because citations can be copied to the local wiki from en.wiki, the English is required when the date-name translation&lt;br /&gt;
function date_name_xlate() is used.&lt;br /&gt;
&lt;br /&gt;
In these tables, season numbering is defined by Extended Date/Time Format (EDTF) Specification (https://www.loc.gov/standards/datetime/)&lt;br /&gt;
which became part of ISO 8601 in 2019.  See '§Sub-year groupings'.  The standard defines various divisions using&lt;br /&gt;
numbers 21-41.  CS1|2 only supports generic seasons.  EDTF does support the distinction between north and south&lt;br /&gt;
hemispere seasons but CS1|2 has no way to make that distinction.&lt;br /&gt;
&lt;br /&gt;
33-36 = Quarter 1, Quarter 2, Quarter 3, Quarter 4 (3 months each)&lt;br /&gt;
&lt;br /&gt;
The standard does not address 'named' dates so, for the purposes of CS1|2, Easter and Christmas are defined here as 98 and 99, which&lt;br /&gt;
should be out of the ISO 8601 (EDTF) range of uses for a while.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local date_names = {&lt;br /&gt;
	['en'] = {																	-- English&lt;br /&gt;
		['long']	= {['January'] = 1, ['February'] = 2, ['March'] = 3, ['April'] = 4, ['May'] = 5, ['June'] = 6, ['July'] = 7, ['August'] = 8, ['September'] = 9, ['October'] = 10, ['November'] = 11, ['December'] = 12},&lt;br /&gt;
		['short']	= {['Jan'] = 1, ['Feb'] = 2, ['Mar'] = 3, ['Apr'] = 4, ['May'] = 5, ['Jun'] = 6, ['Jul'] = 7, ['Aug'] = 8, ['Sep'] = 9, ['Oct'] = 10, ['Nov'] = 11, ['Dec'] = 12},&lt;br /&gt;
		['quarter'] = {['First Quarter'] = 33, ['Second Quarter'] = 34, ['Third Quarter'] = 35, ['Fourth Quarter'] = 36},&lt;br /&gt;
		['season']	= {['Winter'] = 24, ['Spring'] = 21, ['Summer'] = 22, ['Fall'] = 23, ['Autumn'] = 23},&lt;br /&gt;
		['named']	= {['Easter'] = 98, ['Christmas'] = 99},&lt;br /&gt;
		},&lt;br /&gt;
	['local'] = {																-- replace these English date names with the local language equivalents&lt;br /&gt;
		['long']	= {['January'] = 1, ['February'] = 2, ['March'] = 3, ['April'] = 4, ['May'] = 5, ['June'] = 6, ['July'] = 7, ['August'] = 8, ['September'] = 9, ['October'] = 10, ['November'] = 11, ['December'] = 12},&lt;br /&gt;
		['short']	= {['Jan'] = 1, ['Feb'] = 2, ['Mar'] = 3, ['Apr'] = 4, ['May'] = 5, ['Jun'] = 6, ['Jul'] = 7, ['Aug'] = 8, ['Sep'] = 9, ['Oct'] = 10, ['Nov'] = 11, ['Dec'] = 12},&lt;br /&gt;
		['quarter'] = {['First Quarter'] = 33, ['Second Quarter'] = 34, ['Third Quarter'] = 35, ['Fourth Quarter'] = 36},&lt;br /&gt;
		['season']	= {['Winter'] = 24, ['Spring'] = 21, ['Summer'] = 22, ['Fall'] = 23, ['Autumn'] = 23},&lt;br /&gt;
		['named']	= {['Easter'] = 98, ['Christmas'] = 99},&lt;br /&gt;
		},&lt;br /&gt;
	['inv_local_l'] = {},														-- used in date reformatting; copy of date_names['local'].long where k/v are inverted: [1]='&amp;lt;local name&amp;gt;' etc.&lt;br /&gt;
	['inv_local_s'] = {},														-- used in date reformatting; copy of date_names['local'].short where k/v are inverted: [1]='&amp;lt;local name&amp;gt;' etc.&lt;br /&gt;
	['local_digits'] = {['0'] = '0', ['1'] = '1', ['2'] = '2', ['3'] = '3', ['4'] = '4', ['5'] = '5', ['6'] = '6', ['7'] = '7', ['8'] = '8', ['9'] = '9'},	-- used to convert local language digits to Western 0-9&lt;br /&gt;
	['xlate_digits'] = {},&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
for name, i in pairs (date_names['local'].long) do								-- this table is ['name'] = i&lt;br /&gt;
	date_names['inv_local_l'][i] = name;										-- invert to get [i] = 'name' for conversions from ymd&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
for name, i in pairs (date_names['local'].short) do								-- this table is ['name'] = i&lt;br /&gt;
	date_names['inv_local_s'][i] = name;										-- invert to get [i] = 'name' for conversions from ymd&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
for ld, ed in pairs (date_names.local_digits) do								-- make a digit translation table for simple date translation from en to local language using local_digits table&lt;br /&gt;
	date_names.xlate_digits [ed] = ld;											-- en digit becomes index with local digit as the value&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
local df_template_patterns = {													-- table of redirects to {{Use dmy dates}} and {{Use mdy dates}}&lt;br /&gt;
	'{{ *[Uu]se +(dmy) +dates *[|}]',	-- 1159k								-- sorted by approximate transclusion count&lt;br /&gt;
	'{{ *[Uu]se +(mdy) +dates *[|}]',	-- 212k&lt;br /&gt;
	'{{ *[Uu]se +(MDY) +dates *[|}]',	-- 788&lt;br /&gt;
	'{{ *[Uu]se +(DMY) +dates *[|}]',	-- 343&lt;br /&gt;
	'{{ *([Mm]dy) *[|}]',				-- 176&lt;br /&gt;
	'{{ *[Uu]se *(dmy) *[|}]',			-- 156 + 18&lt;br /&gt;
	'{{ *[Uu]se *(mdy) *[|}]',			-- 149 + 11&lt;br /&gt;
	'{{ *([Dd]my) *[|}]',				-- 56&lt;br /&gt;
	'{{ *[Uu]se +(MDY) *[|}]',			-- 5&lt;br /&gt;
	'{{ *([Dd]MY) *[|}]',				-- 3&lt;br /&gt;
	'{{ *[Uu]se(mdy)dates *[|}]',		-- 1&lt;br /&gt;
	'{{ *[Uu]se +(DMY) *[|}]',			-- 0&lt;br /&gt;
	'{{ *([Mm]DY) *[|}]',				-- 0&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
local function get_date_format ()&lt;br /&gt;
	local content = mw.title.getCurrentTitle():getContent() or '';				-- get the content of the article or ''; new pages edited w/ve do not have 'content' until saved; ve does not preview; phab:T221625&lt;br /&gt;
	for _, pattern in ipairs (df_template_patterns) do							-- loop through the patterns looking for {{Use dmy dates}} or {{Use mdy dates}} or any of their redirects&lt;br /&gt;
		local start, _, match = content:find(pattern);							-- match is the three letters indicating desired date format&lt;br /&gt;
		if match then&lt;br /&gt;
			content = content:match ('%b{}', start);							-- get the whole template&lt;br /&gt;
			if content:match ('| *cs1%-dates *= *[lsy][sy]?') then				-- look for |cs1-dates=publication date length access-/archive-date length&lt;br /&gt;
				return match:lower() .. '-' .. content:match ('| *cs1%-dates *= *([lsy][sy]?)');&lt;br /&gt;
			else&lt;br /&gt;
				return match:lower() .. '-all';									-- no |cs1-dates= k/v pair; return value appropriate for use in |df=&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
local global_df = get_date_format ();&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; V O L U M E ,  I S S U E ,  P A G E S &amp;gt;----------------------------------------&lt;br /&gt;
&lt;br /&gt;
These tables hold cite class values (from the template invocation) and identify those templates that support&lt;br /&gt;
|volume=, |issue=, and |page(s)= parameters.  Cite conference and cite map require further qualification which&lt;br /&gt;
is handled in the main module.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local templates_using_volume = {'citation', 'audio-visual', 'book', 'conference', 'encyclopaedia', 'interview', 'journal', 'magazine', 'map', 'news', 'report', 'techreport', 'thesis'}&lt;br /&gt;
local templates_using_issue = {'citation', 'conference', 'episode', 'interview', 'journal', 'magazine', 'map', 'news', 'podcast'}&lt;br /&gt;
local templates_not_using_page = {'audio-visual', 'episode', 'mailinglist', 'newsgroup', 'podcast', 'serial', 'sign', 'speech'}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; K E Y W O R D S &amp;gt;--------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
These tables hold keywords for those parameters that have defined sets of acceptable keywords.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; K E Y W O R D S   T A B L E &amp;gt;--------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
this is a list of keywords; each key in the list is associated with a table of synonymous keywords possibly from&lt;br /&gt;
different languages.&lt;br /&gt;
&lt;br /&gt;
for I18N: add local-language keywords to value table; do not change the key.  For example, adding the German keyword 'ja':&lt;br /&gt;
	['affirmative'] = {'yes', 'true', 'y', 'ja'},&lt;br /&gt;
&lt;br /&gt;
Because CS1|2 templates from en.wiki articles are often copied to other local wikis, it is recommended that the English&lt;br /&gt;
keywords remain in these tables.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local keywords = {&lt;br /&gt;
	['amp'] = {'&amp;amp;', 'amp', 'ampersand'}, 															-- |name-list-style=&lt;br /&gt;
	['and'] = {'and', 'serial'},															-- |name-list-style=&lt;br /&gt;
	['affirmative'] = {'yes', 'true', 'y'},										-- |ignore-isbn-error=, |last-author-amp=, |no-tracking=, |no-pp= -- Used by InternetArchiveBot&lt;br /&gt;
	['afterword'] = {'afterword'},												-- |contribution=&lt;br /&gt;
	['bot: unknown'] = {'bot: unknown'},										-- |url-status= -- Used by InternetArchiveBot&lt;br /&gt;
	['cs1'] = {'cs1'},															-- |mode=&lt;br /&gt;
	['cs2'] = {'cs2'},															-- |mode=&lt;br /&gt;
	['dead'] = {'dead'},														-- |url-status= -- Used by InternetArchiveBot&lt;br /&gt;
	['dmy'] = {'dmy'},															-- |df=&lt;br /&gt;
	['dmy-all'] = {'dmy-all'},													-- |df=&lt;br /&gt;
	['foreword'] = {'foreword'},												-- |contribution=&lt;br /&gt;
	['free'] = {'free'},														-- |url-access= -- Used by InternetArchiveBot&lt;br /&gt;
	['introduction'] = {'introduction'},										-- |contribution=&lt;br /&gt;
	['limited'] = {'limited'},													-- |url-access= -- Used by InternetArchiveBot&lt;br /&gt;
	['live'] = {'live'},														-- |url-status= -- Used by InternetArchiveBot&lt;br /&gt;
	['mdy'] = {'mdy'},															-- |df=&lt;br /&gt;
	['mdy-all'] = {'mdy-all'},													-- |df=&lt;br /&gt;
	['none'] = {'none'},														-- |postscript=, |ref=, |title=, |type= -- Used by InternetArchiveBot&lt;br /&gt;
	['off'] = {'off'},															-- |title= (potentially also: |title-link=, |postscript=, |ref=, |type=)&lt;br /&gt;
	['preface'] = {'preface'},													-- |contribution=&lt;br /&gt;
	['registration'] = {'registration'},										-- |url-access= -- Used by InternetArchiveBot&lt;br /&gt;
	['subscription'] = {'subscription'},										-- |url-access= -- Used by InternetArchiveBot&lt;br /&gt;
	['unfit'] = {'unfit'},														-- |url-status= -- Used by InternetArchiveBot&lt;br /&gt;
	['usurped'] = {'usurped'},													-- |url-status= -- Used by InternetArchiveBot&lt;br /&gt;
	['vanc'] = {'vanc'},														-- |name-list-style=&lt;br /&gt;
	['ymd'] = {'ymd'},															-- |df=&lt;br /&gt;
	['ymd-all'] = {'ymd-all'},													-- |df=&lt;br /&gt;
--	['yMd'] = {'yMd'},															-- |df=; not supported at en.wiki&lt;br /&gt;
--	['yMd-all'] = {'yMd-all'},													-- |df=; not supported at en.wiki&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; X L A T E _ K E Y W O R D S &amp;gt;--------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
this function builds a list, keywords_xlate{}, of the keywords found in keywords{} where the values from keywords{}&lt;br /&gt;
become the keys in keywords_xlate{} and the keys from keywords{} become the values in keywords_xlate{}:&lt;br /&gt;
	['affirmative'] = {'yes', 'true', 'y'},		-- in keywords{}&lt;br /&gt;
becomes&lt;br /&gt;
	['yes'] = 'affirmative',					-- in keywords_xlate{}&lt;br /&gt;
	['true'] = 'affirmative',&lt;br /&gt;
	['y'] = 'affirmative',&lt;br /&gt;
&lt;br /&gt;
the purpose of this function is to act as a translator between a non-English keyword and its English equivalent&lt;br /&gt;
that may be used in other modules of this suite&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function xlate_keywords ()&lt;br /&gt;
	local out_table = {};														-- output goes here&lt;br /&gt;
	for k, keywords_t in pairs (keywords) do									-- spin through the keywords table&lt;br /&gt;
		for _, keyword in ipairs (keywords_t) do								-- for each keyword&lt;br /&gt;
			out_table[keyword] = k;												-- create an entry in the output table where keyword is the key&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	return out_table;&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
local keywords_xlate = xlate_keywords ();										-- the list of translated keywords&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; M A K E _ K E Y W O R D S _ L I S T &amp;gt;------------------------------------------&lt;br /&gt;
&lt;br /&gt;
this function assembles, for parameter-value validation, the list of keywords appropriate to that parameter.&lt;br /&gt;
&lt;br /&gt;
keywords_lists{}, is a table of tables from keywords{}&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function make_keywords_list (keywords_lists)&lt;br /&gt;
	local out_table = {};														-- output goes here&lt;br /&gt;
	&lt;br /&gt;
	for _, keyword_list in ipairs (keywords_lists) do							-- spin through keywords_lists{} and get a table of keywords&lt;br /&gt;
		for _, keyword in ipairs (keyword_list) do								-- spin through keyword_list{} and add each keyword, ...&lt;br /&gt;
			table.insert (out_table, keyword);									-- ... as plain text, to the output list&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	return out_table;&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; K E Y W O R D S _ L I S T S &amp;gt;--------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
this is a list of lists of valid keywords for the various parameters in [key].  Generally the keys in this table&lt;br /&gt;
are the canonical en.wiki parameter names though some are contrived because of use in multiple differently named&lt;br /&gt;
parameters: ['yes_true_y'], ['id-access'].&lt;br /&gt;
&lt;br /&gt;
The function make_keywords_list() extracts the individual keywords from the appropriate list in keywords{}.&lt;br /&gt;
&lt;br /&gt;
The lists in this table are used to validate the keyword assignment for the parameters named in this table's keys.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local keywords_lists = {&lt;br /&gt;
	['yes_true_y'] = make_keywords_list ({keywords.affirmative}),&lt;br /&gt;
	['contribution'] = make_keywords_list ({keywords.afterword, keywords.foreword, keywords.introduction, keywords.preface}),&lt;br /&gt;
	['df'] = make_keywords_list ({keywords.dmy, keywords['dmy-all'], keywords.mdy, keywords['mdy-all'], keywords.ymd, keywords['ymd-all']}),&lt;br /&gt;
--	['df'] = make_keywords_list ({keywords.dmy, keywords['dmy-all'], keywords.mdy, keywords['mdy-all'], keywords.ymd, keywords['ymd-all'], keywords.yMd, keywords['yMd-all']}),	-- not supported at en.wiki&lt;br /&gt;
	['mode'] = make_keywords_list ({keywords.cs1, keywords.cs2}),&lt;br /&gt;
	['name-list-style'] = make_keywords_list ({keywords.amp, keywords['and'], keywords.vanc}),&lt;br /&gt;
	['url-access'] = make_keywords_list ({keywords.subscription, keywords.limited, keywords.registration}),&lt;br /&gt;
	['url-status'] = make_keywords_list ({keywords.dead, keywords.live, keywords.unfit, keywords.usurped, keywords['bot: unknown']}),&lt;br /&gt;
	['id-access'] = make_keywords_list ({keywords.free}),&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; S T R I P M A R K E R S &amp;gt;------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Common pattern definition location for stripmarkers so that we don't have to go hunting for them if (when)&lt;br /&gt;
MediaWiki changes their form.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local stripmarkers = {&lt;br /&gt;
	['any'] = '\127[^\127]*UNIQ%-%-(%a+)%-[%a%d]+%-QINU[^\127]*\127',			-- capture returns name of stripmarker&lt;br /&gt;
	['math'] = '\127[^\127]*UNIQ%-%-math%-[%a%d]+%-QINU[^\127]*\127'			-- math stripmarkers used in coins_cleanup() and coins_replace_math_stripmarker()&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; I N V I S I B L E _ C H A R A C T E R S &amp;gt;--------------------------------------&lt;br /&gt;
&lt;br /&gt;
This table holds non-printing or invisible characters indexed either by name or by Unicode group. Values are decimal&lt;br /&gt;
representations of UTF-8 codes.  The table is organized as a table of tables because the Lua pairs keyword returns&lt;br /&gt;
table data in an arbitrary order.  Here, we want to process the table from top to bottom because the entries at&lt;br /&gt;
the top of the table are also found in the ranges specified by the entries at the bottom of the table.&lt;br /&gt;
&lt;br /&gt;
Also here is a pattern that recognizes stripmarkers that begin and end with the delete characters.  The nowiki&lt;br /&gt;
stripmarker is not an error but some others are because the parameter values that include them become part of the&lt;br /&gt;
template's metadata before stripmarker replacement.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local invisible_chars = {&lt;br /&gt;
	{'replacement', '\239\191\189'},											-- U+FFFD, EF BF BD&lt;br /&gt;
	{'zero width joiner', '\226\128\141'},										-- U+200D, E2 80 8D&lt;br /&gt;
	{'zero width space', '\226\128\139'},										-- U+200B, E2 80 8B&lt;br /&gt;
	{'hair space', '\226\128\138'},												-- U+200A, E2 80 8A&lt;br /&gt;
	{'soft hyphen', '\194\173'},												-- U+00AD, C2 AD&lt;br /&gt;
	{'horizontal tab', '\009'},													-- U+0009 (HT), 09&lt;br /&gt;
	{'line feed', '\010'},														-- U+000A (LF), 0A&lt;br /&gt;
	{'no-break space', '\194\160'},												-- U+00A0 (NBSP), C2 A0&lt;br /&gt;
	{'carriage return', '\013'},												-- U+000D (CR), 0D&lt;br /&gt;
	{'stripmarker', stripmarkers.any},											-- stripmarker; may or may not be an error; capture returns the stripmaker type&lt;br /&gt;
	{'delete', '\127'},															-- U+007F (DEL), 7F; must be done after stripmarker test&lt;br /&gt;
	{'C0 control', '[\000-\008\011\012\014-\031]'},								-- U+0000–U+001F (NULL–US), 00–1F (except HT, LF, CR (09, 0A, 0D))&lt;br /&gt;
	{'C1 control', '[\194\128-\194\159]'},										-- U+0080–U+009F (XXX–APC), C2 80 – C2 9F&lt;br /&gt;
--	{'Specials', '[\239\191\185-\239\191\191]'},								-- U+FFF9-U+FFFF, EF BF B9 – EF BF BF&lt;br /&gt;
--	{'Private use area', '[\238\128\128-\239\163\191]'},						-- U+E000–U+F8FF, EE 80 80 – EF A3 BF&lt;br /&gt;
--	{'Supplementary Private Use Area-A', '[\243\176\128\128-\243\191\191\189]'},	-- U+F0000–U+FFFFD, F3 B0 80 80 – F3 BF BF BD&lt;br /&gt;
--	{'Supplementary Private Use Area-B', '[\244\128\128\128-\244\143\191\189]'},	-- U+100000–U+10FFFD, F4 80 80 80 – F4 8F BF BD&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
--[[&lt;br /&gt;
Indic script makes use of zero width joiner as a character modifier so zwj characters must be left in.  This&lt;br /&gt;
pattern covers all of the unicode characters for these languages:&lt;br /&gt;
	Devanagari					0900–097F – https://unicode.org/charts/PDF/U0900.pdf&lt;br /&gt;
		Devanagari extended		A8E0–A8FF – https://unicode.org/charts/PDF/UA8E0.pdf&lt;br /&gt;
	Bengali						0980–09FF – https://unicode.org/charts/PDF/U0980.pdf&lt;br /&gt;
	Gurmukhi					0A00–0A7F – https://unicode.org/charts/PDF/U0A00.pdf&lt;br /&gt;
	Gujarati					0A80–0AFF – https://unicode.org/charts/PDF/U0A80.pdf&lt;br /&gt;
	Oriya						0B00–0B7F – https://unicode.org/charts/PDF/U0B00.pdf&lt;br /&gt;
	Tamil						0B80–0BFF – https://unicode.org/charts/PDF/U0B80.pdf&lt;br /&gt;
	Telugu						0C00–0C7F – https://unicode.org/charts/PDF/U0C00.pdf&lt;br /&gt;
	Kannada						0C80–0CFF – https://unicode.org/charts/PDF/U0C80.pdf&lt;br /&gt;
	Malayalam					0D00–0D7F – https://unicode.org/charts/PDF/U0D00.pdf&lt;br /&gt;
plus the not-necessarily Indic scripts for Sinhala and Burmese:&lt;br /&gt;
	Sinhala						0D80-0DFF - https://unicode.org/charts/PDF/U0D80.pdf&lt;br /&gt;
	Myanmar						1000-109F - https://unicode.org/charts/PDF/U1000.pdf&lt;br /&gt;
		Myanmar extended A		AA60-AA7F - https://unicode.org/charts/PDF/UAA60.pdf&lt;br /&gt;
		Myanmar extended B		A9E0-A9FF - https://unicode.org/charts/PDF/UA9E0.pdf&lt;br /&gt;
the pattern is used by has_invisible_chars() and coins_cleanup()&lt;br /&gt;
TODO: find a better place for this?&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local indic_script = '[\224\164\128-\224\181\191\224\163\160-\224\183\191\225\128\128-\225\130\159\234\167\160-\234\167\191\234\169\160-\234\169\191]';&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; L A N G U A G E   S U P P O R T &amp;gt;----------------------------------------------&lt;br /&gt;
&lt;br /&gt;
These tables and constants support various language-specific functionality.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local this_wiki_code = mw.getContentLanguage():getCode();						-- get this wiki's language code&lt;br /&gt;
	if string.match (mw.site.server, 'wikidata') then&lt;br /&gt;
		this_wiki_code = mw.getCurrentFrame():preprocess('{{int:lang}}');		-- on Wikidata so use interface language setting instead&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
local languages = mw.language.fetchLanguageNames (this_wiki_code, 'all');		-- get a list of language names known to Wikimedia; used for |language= and interwiki tests&lt;br /&gt;
&lt;br /&gt;
local inter_wiki_map = {};														-- map of inter-wiki prefixes that are language-code prefixes&lt;br /&gt;
	for k, v in pairs (mw.site.interwikiMap ('local')) do						-- spin through the base inter-wiki map (limited to local)&lt;br /&gt;
		if languages[v[&amp;quot;prefix&amp;quot;]] then											-- if the prefix matches a known language code&lt;br /&gt;
			inter_wiki_map[v[&amp;quot;prefix&amp;quot;]] = true;									-- add it to our local map&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
local local_lang_cat_enable = false;											-- set to true to categorize pages where |language=&amp;lt;local wiki's language&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; S C R I P T _ L A N G _ C O D E S &amp;gt;--------------------------------------------&lt;br /&gt;
&lt;br /&gt;
This table is used to hold ISO 639-1 two-character and ISO 639-3 three-character language codes that apply only&lt;br /&gt;
to |script-title= and |script-chapter=&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local script_lang_codes = {&lt;br /&gt;
	'am', 'ar', 'be', 'bg', 'bn', 'bo', 'bs', 'dv', 'dz', 'el', 'fa',&lt;br /&gt;
	'gu', 'he', 'hi', 'hy', 'ja', 'ka', 'kk', 'km', 'kn', 'ko', 'ku',&lt;br /&gt;
	'lo', 'mk', 'ml', 'mn', 'mr', 'my', 'ne', 'or', 'ota', 'ps', 'ru',&lt;br /&gt;
	'sd', 'si', 'sr', 'ta', 'tg', 'th', 'ug', 'uk', 'ur', 'uz', 'yi', 'zh'&lt;br /&gt;
	};&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; L A N G U A G E   R E M A P P I N G &amp;gt;------------------------------------------&lt;br /&gt;
&lt;br /&gt;
These tables hold language information that is different (correct) from MediaWiki's definitions&lt;br /&gt;
&lt;br /&gt;
For each ['code'] = 'language name' in lang_code_remap{} there must be a matching ['language name'] = {'language name', 'code'} in lang_name_remap{}&lt;br /&gt;
&lt;br /&gt;
lang_code_remap{}:&lt;br /&gt;
	key is always lowercase ISO 639-1, -2, -3 language code or a valid lowercase IETF language tag&lt;br /&gt;
	value is properly spelled and capitalized language name associated with key&lt;br /&gt;
	only one language name per key;&lt;br /&gt;
	key/value pair must have matching entry in lang_name_remap{}&lt;br /&gt;
&lt;br /&gt;
lang_name_remap{}:&lt;br /&gt;
	key is always lowercase language name&lt;br /&gt;
	value is a table the holds correctly spelled and capitalized language name [1] and associated code [2] (code must match a code key in lang_code_remap{})&lt;br /&gt;
	may have multiple keys referring to a common preferred name and code; For example:&lt;br /&gt;
		['kolsch'] and ['kölsch'] both refer to 'Kölsch' and 'ksh'&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local lang_code_remap = {														-- used for |language= and |script-title= / |script-chapter=&lt;br /&gt;
	['als'] = 'Tosk Albanian',													-- MediaWiki returns Alemannisch &lt;br /&gt;
	['bh'] = 'Bihari',															-- MediaWiki uses 'bh' as a subdomain name for Bhojpuri Wikipedia: bh.wikipedia.org&lt;br /&gt;
	['bla'] = 'Blackfoot',														-- MediaWiki/IANA/ISO 639: Siksika; use en.wiki preferred name&lt;br /&gt;
	['bn'] = 'Bengali',															-- MediaWiki returns Bangla&lt;br /&gt;
	['ca-valencia'] = 'Valencian',												-- IETF variant of Catalan&lt;br /&gt;
	['crh'] = 'Crimean Tatar',													-- synonymous with Crimean Turkish (return value from {{#language:crh|en}})&lt;br /&gt;
	['ilo'] = 'Ilocano',														-- MediaWiki/IANA/ISO 639: Iloko; use en.wiki preferred name&lt;br /&gt;
	['ksh'] = 'Kölsch',															-- MediaWiki: Colognian; use IANA/ISO 639 preferred name&lt;br /&gt;
	['ksh-x-colog'] = 'Colognian',												-- override MediaWiki ksh; no IANA/ISO 639 code for Colognian; IETF private code created at Module:Lang/data&lt;br /&gt;
	['mis-x-ripuar'] = 'Ripuarian',												-- override MediaWiki ksh; no IANA/ISO 639 code for Ripuarian; IETF private code created at Module:Lang/data&lt;br /&gt;
	['nan-tw'] = 'Taiwanese Hokkien',											-- make room for MediaWiki/IANA/ISO 639 nan: Min Nan Chinese and support en.wiki preferred name&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
local lang_name_remap = {														-- used for |language=&lt;br /&gt;
	['alemannisch'] = {'Swiss German', 'gsw'},									-- not an ISO or IANA language name; MediaWiki uses 'als' as a subdomain name for Alemannic Wikipedia: als.wikipedia.org&lt;br /&gt;
	['bangla'] = {'Bengali', 'bn'},												-- MediaWiki returns Bangla (the endonym) but we want Bengali (the exonym); here we remap&lt;br /&gt;
	['bengali'] = {'Bengali', 'bn'},											-- MediaWiki doesn't use exonym so here we provide correct language name and 639-1 code&lt;br /&gt;
	['bhojpuri'] = {'Bhojpuri', 'bho'},											-- MediaWiki uses 'bh' as a subdomain name for Bhojpuri Wikipedia: bh.wikipedia.org&lt;br /&gt;
	['bihari'] = {'Bihari', 'bh'},												-- MediaWiki replaces 'Bihari' with 'Bhojpuri' so 'Bihari' cannot be found&lt;br /&gt;
	['blackfoot'] = {'Blackfoot', 'bla'},										-- MediaWiki/IANA/ISO 639: Siksika; use en.wiki preferred name&lt;br /&gt;
	['colognian'] = {'Colognian', 'ksh-x-colog'},								-- MediaWiki preferred name for ksh&lt;br /&gt;
	['crimean tatar'] = {'Crimean Tatar', 'crh'},								-- MediaWiki uses 'crh' as a subdomain name for Crimean Tatar Wikipedia: crh.wikipedia.org&lt;br /&gt;
	['ilocano'] = {'Ilocano', 'ilo'},											-- MediaWiki/IANA/ISO 639: Iloko; use en.wiki preferred name&lt;br /&gt;
	['kolsch'] = {'Kölsch', 'ksh'},												-- use IANA/ISO 639 preferred name (use non-diacritical o instead of umlaut ö)&lt;br /&gt;
	['kölsch'] = {'Kölsch', 'ksh'},												-- use IANA/ISO 639 preferred name&lt;br /&gt;
	['ripuarian'] = {'Ripuarian', 'mis-x-ripuar'},								-- group of dialects; no code in MediaWiki or in IANA/ISO 639&lt;br /&gt;
--	['siksika'] = {'Siksika', 'bla'},											-- MediaWiki/IANA/ISO 639 preferred name: Siksika&lt;br /&gt;
	['taiwanese hokkien'] = {'Taiwanese Hokkien', 'nan-TW'},					-- make room for MediaWiki/IANA/ISO 639 nan: Min Nan Chinese &lt;br /&gt;
	['tosk albanian'] = {'Tosk Albanian', 'als'},								-- MediaWiki replaces 'Tosk Albanian' with 'Alemannisch' so 'Tosk Albanian' cannot be found&lt;br /&gt;
	['valencian'] = {'Valencian', 'ca'},										-- variant of Catalan; categorizes as Catalan&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; P R O P E R T I E S _ C A T E G O R I E S &amp;gt;------------------------------------&lt;br /&gt;
&lt;br /&gt;
Here we name properties categories&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local prop_cats = {&lt;br /&gt;
	['foreign_lang_source'] = 'CS1 $1-language sources ($2)',					-- |language= categories; $1 is foreign-language name, $2 is ISO639-1 code&lt;br /&gt;
	['foreign_lang_source_2'] = 'CS1 foreign language sources (ISO 639-2)|$1',	-- |language= category; a cat for ISO639-2 languages; $1 is the ISO 639-2 code used as a sort key&lt;br /&gt;
	['local_lang_source'] = 'CS1 $1-language sources ($2)',						-- |language= categories; $1 is local-language name, $2 is ISO639-1 code; not emitted when local_lang_cat_enable is false&lt;br /&gt;
	['location test'] = 'CS1 location test',&lt;br /&gt;
	['script'] = 'CS1 uses foreign language script',							-- when language specified by |script-title=xx: doesn't have its own category&lt;br /&gt;
	['script_with_name'] = 'CS1 uses $1-language script ($2)',					-- |script-title=xx: has matching category; $1 is language name, $2 is ISO639-1 code&lt;br /&gt;
	['jul_greg_uncertainty'] = 'CS1: Julian–Gregorian uncertainty',				-- probably temporary cat to identify scope of template with dates 1 October 1582 – 1 January 1926&lt;br /&gt;
	['long_vol'] = 'CS1: long volume value',									-- probably temporary cat to identify scope of |volume= values longer than 4 charachters&lt;br /&gt;
	['year_range_abbreviated'] = 'CS1: abbreviated year range',					-- probably temporary cat to identify scope of |date=, |year= values using YYYY–YY form&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; T I T L E _ T Y P E S &amp;gt;--------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Here we map a template's CitationClass to TitleType (default values for |type= parameter)&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local title_types = {&lt;br /&gt;
	['AV-media-notes'] = 'Media notes',&lt;br /&gt;
	['interview'] = 'Interview',&lt;br /&gt;
	['mailinglist'] = 'Mailing list',&lt;br /&gt;
	['map'] = 'Map',&lt;br /&gt;
	['podcast'] = 'Podcast',&lt;br /&gt;
	['pressrelease'] = 'Press release',&lt;br /&gt;
	['report'] = 'Report',&lt;br /&gt;
	['techreport'] = 'Technical report',&lt;br /&gt;
	['thesis'] = 'Thesis',&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[=========================&amp;lt;&amp;lt; E R R O R   M E S S A G I N G &amp;gt;&amp;gt;===============================================&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; E R R O R   M E S S A G E   S U P P L I M E N T S &amp;gt;----------------------------&lt;br /&gt;
&lt;br /&gt;
I18N for those messages that are supplemented with additional specific text that describes the reason for&lt;br /&gt;
the error&lt;br /&gt;
&lt;br /&gt;
TODO: merge this with special_case_translations{}?&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local err_msg_supl = {&lt;br /&gt;
	['char'] = 'invalid character',												-- |isbn=, |sbn=&lt;br /&gt;
	['check'] = 'checksum',														-- |isbn=, |sbn=&lt;br /&gt;
	['flag'] = 'flag',															-- |archive-url=&lt;br /&gt;
	['form'] = 'invalid form',													-- |isbn=, |sbn=&lt;br /&gt;
	['group'] = 'invalid group id',												-- |isbn=&lt;br /&gt;
	['initials'] = 'initials',													-- Vancouver&lt;br /&gt;
	['journal'] = 'journal',													-- |bibcode=&lt;br /&gt;
	['length'] = 'length',														-- |isbn=, |bibcode=, |sbn=&lt;br /&gt;
	['liveweb'] = 'liveweb',													-- |archive-url=&lt;br /&gt;
	['missing comma'] = 'missing comma',										-- Vancouver&lt;br /&gt;
	['name'] = 'name',															-- Vancouver&lt;br /&gt;
	['non-Latin char'] = 'non-Latin character',									-- Vancouver&lt;br /&gt;
	['path'] = 'path',															-- |archive-url=&lt;br /&gt;
	['prefix'] = 'invalid prefix',												-- |isbn=&lt;br /&gt;
	['punctuation'] = 'punctuation',											-- Vancouver&lt;br /&gt;
	['save'] = 'save command',													-- |archive-url=&lt;br /&gt;
	['suffix'] = 'suffix',														-- Vancouver&lt;br /&gt;
	['timestamp'] = 'timestamp',												-- |archive-url=&lt;br /&gt;
	['value'] = 'value',														-- |bibcode=&lt;br /&gt;
	['year'] = 'year',															-- |bibcode=&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; E R R O R _ C O N D I T I O N S &amp;gt;----------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Error condition table.  This table has two sections: errors at the top, maintenance at the bottom.  Maint 'messaging'&lt;br /&gt;
does not have a 'message' (message=nil)&lt;br /&gt;
&lt;br /&gt;
The following contains a list of IDs for various error conditions defined in the code.  For each ID, we specify a&lt;br /&gt;
text message to display, an error category to include, and whether the error message should be wrapped as a hidden comment.&lt;br /&gt;
&lt;br /&gt;
Anchor changes require identical changes to matching anchor in Help:CS1 errors&lt;br /&gt;
&lt;br /&gt;
TODO: rename error_conditions{} to something more generic; create separate error and maint tables inside that?&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local error_conditions = {&lt;br /&gt;
	err_accessdate_missing_url = {&lt;br /&gt;
		message = '&amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;access-date=&amp;lt;/code&amp;gt; requires &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;url=&amp;lt;/code&amp;gt;',&lt;br /&gt;
		anchor = 'accessdate_missing_url',&lt;br /&gt;
		category = 'Pages using citations with accessdate and no URL',&lt;br /&gt;
		hidden = false&lt;br /&gt;
 		},&lt;br /&gt;
	err_apostrophe_markup = {&lt;br /&gt;
		message = 'Italic or bold markup not allowed in: &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;$1=&amp;lt;/code&amp;gt;',	-- $1 is parameter name&lt;br /&gt;
		anchor = 'apostrophe_markup',&lt;br /&gt;
		category = 'CS1 errors: markup',&lt;br /&gt;
		hidden = false&lt;br /&gt;
 		},&lt;br /&gt;
	err_archive_missing_date = {&lt;br /&gt;
		message = '&amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;archive-url=&amp;lt;/code&amp;gt; requires &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;archive-date=&amp;lt;/code&amp;gt;',&lt;br /&gt;
		anchor = 'archive_missing_date',&lt;br /&gt;
		category = 'Pages with archiveurl citation errors',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_archive_missing_url = {&lt;br /&gt;
		message = '&amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;archive-url=&amp;lt;/code&amp;gt; requires &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;url=&amp;lt;/code&amp;gt;',&lt;br /&gt;
		anchor = 'archive_missing_url',&lt;br /&gt;
		category = 'Pages with archiveurl citation errors',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_archive_url = {&lt;br /&gt;
		message = '&amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;archive-url=&amp;lt;/code&amp;gt; is malformed: $1',	-- $1 is error message detail&lt;br /&gt;
		anchor = 'archive_url',&lt;br /&gt;
		category = 'Pages with archiveurl citation errors',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_arxiv_missing = {&lt;br /&gt;
		message = '&amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;arxiv=&amp;lt;/code&amp;gt; required',&lt;br /&gt;
		anchor = 'arxiv_missing',&lt;br /&gt;
		category = 'CS1 errors: arXiv',											-- same as bad arxiv&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_bad_arxiv = {&lt;br /&gt;
		message = 'Check &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;arxiv=&amp;lt;/code&amp;gt; value',&lt;br /&gt;
		anchor = 'bad_arxiv',&lt;br /&gt;
		category = 'CS1 errors: arXiv',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_bad_asin = {&lt;br /&gt;
		message = 'Check &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;asin=&amp;lt;/code&amp;gt; value',&lt;br /&gt;
		anchor = 'bad_asin',&lt;br /&gt;
		category ='CS1 errors: ASIN',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_bad_bibcode = {&lt;br /&gt;
		message = 'Check &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;bibcode=&amp;lt;/code&amp;gt; $1',		-- $1 is error message detail&lt;br /&gt;
		anchor = 'bad_bibcode',&lt;br /&gt;
		category = 'CS1 errors: bibcode',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_bad_biorxiv = {&lt;br /&gt;
		message = 'Check &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;biorxiv=&amp;lt;/code&amp;gt; value',&lt;br /&gt;
		anchor = 'bad_biorxiv',&lt;br /&gt;
		category = 'CS1 errors: bioRxiv',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_bad_citeseerx = {&lt;br /&gt;
		message = 'Check &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;citeseerx=&amp;lt;/code&amp;gt; value',&lt;br /&gt;
		anchor = 'bad_citeseerx',&lt;br /&gt;
		category = 'CS1 errors: citeseerx',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_bad_date = {&lt;br /&gt;
--		message = 'Check date values in: &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;$1&amp;lt;/code&amp;gt;',		-- $1 is parameter name&lt;br /&gt;
		message = 'Check date values in: $1',		-- $1 is parameter name&lt;br /&gt;
		anchor = 'bad_date',&lt;br /&gt;
		category = 'CS1 errors: dates',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_bad_doi = {&lt;br /&gt;
		message = 'Check &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;doi=&amp;lt;/code&amp;gt; value',&lt;br /&gt;
		anchor = 'bad_doi',&lt;br /&gt;
		category = 'CS1 errors: DOI',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_bad_hdl = {&lt;br /&gt;
		message = 'Check &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;hdl=&amp;lt;/code&amp;gt; value',&lt;br /&gt;
		anchor = 'bad_hdl',&lt;br /&gt;
		category = 'CS1 errors: HDL',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_bad_isbn = {&lt;br /&gt;
		message = 'Check &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;isbn=&amp;lt;/code&amp;gt; value: $1',	-- $1 is error message detail&lt;br /&gt;
		anchor = 'bad_isbn',&lt;br /&gt;
		category = 'CS1 errors: ISBN',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_bad_ismn = {&lt;br /&gt;
		message = 'Check &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;ismn=&amp;lt;/code&amp;gt; value',&lt;br /&gt;
		anchor = 'bad_ismn',&lt;br /&gt;
		category = 'CS1 errors: ISMN',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_bad_issn = {&lt;br /&gt;
		message = 'Check &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;$1issn=&amp;lt;/code&amp;gt; value',	-- $1 is 'e' or '' for eissn or issn&lt;br /&gt;
		anchor = 'bad_issn',&lt;br /&gt;
		category = 'CS1 errors: ISSN',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_bad_jfm = {&lt;br /&gt;
		message = 'Check &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;jfm=&amp;lt;/code&amp;gt; value',&lt;br /&gt;
		anchor = 'bad_jfm',&lt;br /&gt;
		category = 'CS1 errors: JFM',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_bad_lccn = {&lt;br /&gt;
		message = 'Check &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;lccn=&amp;lt;/code&amp;gt; value',&lt;br /&gt;
		anchor = 'bad_lccn',&lt;br /&gt;
		category = 'CS1 errors: LCCN',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_bad_mr = {&lt;br /&gt;
		message = 'Check &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;mr=&amp;lt;/code&amp;gt; value',&lt;br /&gt;
		anchor = 'bad_mr',&lt;br /&gt;
		category = 'CS1 errors: MR',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_bad_ol = {&lt;br /&gt;
		message = 'Check &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;ol=&amp;lt;/code&amp;gt; value',&lt;br /&gt;
		anchor = 'bad_ol',&lt;br /&gt;
		category = 'CS1 errors: OL',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_bad_paramlink = {														-- for |title-link=, |author/editor/translator-link=, |series-link=, |episode-link=&lt;br /&gt;
		message = 'Check &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;$1=&amp;lt;/code&amp;gt; value',		-- $1 is parameter name&lt;br /&gt;
		anchor = 'bad_paramlink',&lt;br /&gt;
		category = 'CS1 errors: parameter link',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_bad_pmc = {&lt;br /&gt;
		message = 'Check &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;pmc=&amp;lt;/code&amp;gt; value',&lt;br /&gt;
		anchor = 'bad_pmc',&lt;br /&gt;
		category = 'CS1 errors: PMC',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_bad_pmid = {&lt;br /&gt;
		message = 'Check &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;pmid=&amp;lt;/code&amp;gt; value',&lt;br /&gt;
		anchor = 'bad_pmid',&lt;br /&gt;
		category = 'CS1 errors: PMID',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_bad_oclc = {&lt;br /&gt;
		message = 'Check &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;oclc=&amp;lt;/code&amp;gt; value',&lt;br /&gt;
		anchor = 'bad_oclc',&lt;br /&gt;
		category = 'CS1 errors: OCLC',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	bad_s2cid_err = {&lt;br /&gt;
		message = 'Check &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;s2cid=&amp;lt;/code&amp;gt; value',&lt;br /&gt;
		anchor = 'bad_s2cid',&lt;br /&gt;
		category = 'CS1 errors: S2CID',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_bad_sbn = {&lt;br /&gt;
		message = 'Check &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;sbn=&amp;lt;/code&amp;gt; value: $1',	-- $1 is error message detail&lt;br /&gt;
		anchor = 'bad_sbn',&lt;br /&gt;
		category = 'CS1 errors: SBN',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_bad_ssrn = {&lt;br /&gt;
		message = 'Check &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;ssrn=&amp;lt;/code&amp;gt; value',&lt;br /&gt;
		anchor = 'bad_ssrn',&lt;br /&gt;
		category = 'CS1 errors: SSRN',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_bad_url = {&lt;br /&gt;
		message = 'Check $1 value',												-- $1 is parameter name&lt;br /&gt;
		anchor = 'bad_url',&lt;br /&gt;
		category = 'Pages with URL errors',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_bad_usenet_id = {&lt;br /&gt;
		message = 'Check &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;message-id=&amp;lt;/code&amp;gt; value',&lt;br /&gt;
		anchor = 'bad_message_id',&lt;br /&gt;
		category = 'CS1 errors: message-id',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_bad_zbl = {&lt;br /&gt;
		message = 'Check &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;zbl=&amp;lt;/code&amp;gt; value',&lt;br /&gt;
		anchor = 'bad_zbl',&lt;br /&gt;
		category = 'CS1 errors: ZBL',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_bare_url_missing_title = {&lt;br /&gt;
		message = '$1 missing title',											-- $1 is parameter name&lt;br /&gt;
		anchor = 'bare_url_missing_title',&lt;br /&gt;
		category = 'Pages with citations having bare URLs',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_biorxiv_missing = {&lt;br /&gt;
		message = '&amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;biorxiv=&amp;lt;/code&amp;gt; required',&lt;br /&gt;
		anchor = 'biorxiv_missing',&lt;br /&gt;
		category = 'CS1 errors: bioRxiv',										-- same as bad bioRxiv&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_chapter_ignored = {&lt;br /&gt;
		message = '&amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;$1=&amp;lt;/code&amp;gt; ignored',			-- $1 is parameter name&lt;br /&gt;
		anchor = 'chapter_ignored',&lt;br /&gt;
		category = 'CS1 errors: chapter ignored',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_citation_missing_title = {&lt;br /&gt;
		message = 'Missing or empty &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;$1=&amp;lt;/code&amp;gt;',	-- $1 is parameter name&lt;br /&gt;
		anchor = 'citation_missing_title',&lt;br /&gt;
		category = 'Pages with citations lacking titles',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_citeseerx_missing = {&lt;br /&gt;
		message = '&amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;citeseerx=&amp;lt;/code&amp;gt; required',&lt;br /&gt;
		anchor = 'citeseerx_missing',&lt;br /&gt;
		category = 'CS1 errors: citeseerx',										-- same as bad citeseerx&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_cite_web_url = {														-- this error applies to cite web and to cite podcast&lt;br /&gt;
		message = 'Missing or empty &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;url=&amp;lt;/code&amp;gt;',&lt;br /&gt;
		anchor = 'cite_web_url',&lt;br /&gt;
		category = 'Pages using web citations with no URL',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_class_ignored = {&lt;br /&gt;
		message = '&amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;class=&amp;lt;/code&amp;gt; ignored',&lt;br /&gt;
		anchor = 'class_ignored',&lt;br /&gt;
		category = 'CS1 errors: class',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_contributor_ignored = {&lt;br /&gt;
		message = '&amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;contributor=&amp;lt;/code&amp;gt; ignored',&lt;br /&gt;
		anchor = 'contributor_ignored',&lt;br /&gt;
		category = 'CS1 errors: contributor',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_contributor_missing_required_param = {&lt;br /&gt;
		message = '&amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;contributor=&amp;lt;/code&amp;gt; requires &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;$1=&amp;lt;/code&amp;gt;',	-- $1 is parameter name&lt;br /&gt;
		anchor = 'contributor_missing_required_param',&lt;br /&gt;
		category = 'CS1 errors: contributor',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_deprecated_params = {&lt;br /&gt;
		message = 'Cite uses deprecated parameter &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;$1=&amp;lt;/code&amp;gt;',	-- $1 is parameter name&lt;br /&gt;
		anchor = 'deprecated_params',&lt;br /&gt;
		category = 'CS1 errors: deprecated parameters',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_disp_name = {&lt;br /&gt;
		message = 'Invalid &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;display-$1=$2&amp;lt;/code&amp;gt;',	-- $1 is 'authors', 'contributors', 'editors', 'interviewers', 'translators'; gets value from special_case_translation table&lt;br /&gt;
		anchor = 'disp_name',&lt;br /&gt;
		category = 'CS1 errors: display-names',&lt;br /&gt;
		hidden = false,&lt;br /&gt;
		},&lt;br /&gt;
	err_doibroken_missing_doi = {&lt;br /&gt;
		message = '&amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;$1=&amp;lt;/code&amp;gt; requires &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;doi=&amp;lt;/code&amp;gt;',	-- $1 is parameter name&lt;br /&gt;
		anchor = 'doibroken_missing_doi',&lt;br /&gt;
		category = 'CS1 errors: DOI',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_empty_citation = {&lt;br /&gt;
		message = 'Empty citation',&lt;br /&gt;
		anchor = 'empty_citation',&lt;br /&gt;
		category = 'Pages with empty citations',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_etal = {&lt;br /&gt;
		message = 'Explicit use of et al. in: &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;$1=&amp;lt;/code&amp;gt;',	-- $1 is parameter name&lt;br /&gt;
		anchor = 'explicit_et_al',&lt;br /&gt;
		category = 'CS1 errors: explicit use of et al.',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_first_missing_last = {&lt;br /&gt;
		message = '&amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;$1=&amp;lt;/code&amp;gt; missing &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;$2=&amp;lt;/code&amp;gt;',	-- $1 is first alias, $2 is matching last alias&lt;br /&gt;
		anchor = 'first_missing_last',&lt;br /&gt;
		category = 'CS1 errors: missing name',									-- author, contributor, editor, interviewer, translator&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_format_missing_url = {&lt;br /&gt;
		message = '&amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;$1=&amp;lt;/code&amp;gt; requires &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;$2=&amp;lt;/code&amp;gt;',	-- $1 is format parameter $2 is url parameter&lt;br /&gt;
		anchor = 'format_missing_url',&lt;br /&gt;
		category = 'Pages using citations with format and no URL',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_generic_title = {&lt;br /&gt;
		message = 'Cite uses generic title',&lt;br /&gt;
		anchor = 'generic_title',&lt;br /&gt;
		category = 'CS1 errors: generic title',&lt;br /&gt;
		hidden = false,&lt;br /&gt;
		},&lt;br /&gt;
	err_invalid_param_val = {&lt;br /&gt;
		message = 'Invalid &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;$1=$2&amp;lt;/code&amp;gt;',			-- $1 is parameter name $2 is parameter value&lt;br /&gt;
		anchor = 'invalid_param_val',&lt;br /&gt;
		category = 'CS1 errors: invalid parameter value',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_invisible_char = {&lt;br /&gt;
		message = '$1 in $2 at position $3',									-- $1 is invisible char $2 is parameter name $3 is position number&lt;br /&gt;
		anchor = 'invisible_char',&lt;br /&gt;
		category = 'CS1 errors: invisible characters',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_missing_name = {&lt;br /&gt;
		message = 'Missing &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;$1$2=&amp;lt;/code&amp;gt;',			-- $1 is modified NameList; $2 is enumerator&lt;br /&gt;
		anchor = 'missing_name',&lt;br /&gt;
		category = 'CS1 errors: missing name',									-- author, contributor, editor, interviewer, translator&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_missing_periodical = {&lt;br /&gt;
		message = 'Cite $1 requires &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;$2=&amp;lt;/code&amp;gt;',	-- $1 is cs1 template name; $2 is canonical periodical parameter name for cite $1&lt;br /&gt;
		anchor = 'missing_periodical',&lt;br /&gt;
		category = 'CS1 errors: missing periodical',&lt;br /&gt;
		hidden = true&lt;br /&gt;
		},&lt;br /&gt;
	err_missing_pipe = {&lt;br /&gt;
		message = 'Missing pipe in: &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;$1=&amp;lt;/code&amp;gt;',	-- $1 is parameter name&lt;br /&gt;
		anchor = 'missing_pipe',&lt;br /&gt;
		category = 'CS1 errors: missing pipe',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_param_access_requires_param = {&lt;br /&gt;
		message = '&amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;$1-access=&amp;lt;/code&amp;gt; requires &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;$1=&amp;lt;/code&amp;gt;',	-- $1 is parameter name&lt;br /&gt;
		anchor = 'param_access_requires_param',&lt;br /&gt;
		category = 'CS1 errors: param-access',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_param_has_ext_link = {&lt;br /&gt;
		message = 'External link in &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;$1&amp;lt;/code&amp;gt;',			-- $1 is parameter name&lt;br /&gt;
		anchor = 'param_has_ext_link',&lt;br /&gt;
		category = 'CS1 errors: external links',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_parameter_ignored = {&lt;br /&gt;
		message = 'Unknown parameter &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;$1=&amp;lt;/code&amp;gt; ignored',	-- $1 is parameter name&lt;br /&gt;
		anchor = 'parameter_ignored',&lt;br /&gt;
		category = 'Pages with citations using unsupported parameters',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_parameter_ignored_suggest = {&lt;br /&gt;
		message = 'Unknown parameter &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;$1=&amp;lt;/code&amp;gt; ignored (&amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;$2=&amp;lt;/code&amp;gt; suggested)',	-- $1 is unknown parameter $2 is suggested parameter name&lt;br /&gt;
		anchor = 'parameter_ignored_suggest',&lt;br /&gt;
		category = 'Pages with citations using unsupported parameters',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_redundant_parameters = {&lt;br /&gt;
		message = 'More than one of $1 specified',								-- $1 is error message detail&lt;br /&gt;
		anchor = 'redundant_parameters',&lt;br /&gt;
		category = 'Pages with citations having redundant parameters',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_script_parameter = {&lt;br /&gt;
		message = 'Invalid &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;$1=&amp;lt;/code&amp;gt;: $2',		-- $1 is parameter name $2 is script language code or error detail&lt;br /&gt;
		anchor = 'script_parameter',&lt;br /&gt;
		category = 'CS1 errors: script parameters',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_ssrn_missing = {&lt;br /&gt;
		message = '&amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;ssrn=&amp;lt;/code&amp;gt; required',&lt;br /&gt;
		anchor = 'ssrn_missing',&lt;br /&gt;
		category = 'CS1 errors: ssrn',											-- same as bad arxiv&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_text_ignored = {&lt;br /&gt;
		message = 'Text &amp;quot;$1&amp;quot; ignored',											-- $1 is ignored text&lt;br /&gt;
		anchor = 'text_ignored',&lt;br /&gt;
		category = 'Pages with citations using unnamed parameters',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_trans_missing_title = {&lt;br /&gt;
		message = '&amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;trans-$1=&amp;lt;/code&amp;gt; requires &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;$1=&amp;lt;/code&amp;gt; or  &amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;script-$1=&amp;lt;/code&amp;gt;',	-- $1 is base parameter name&lt;br /&gt;
		anchor = 'trans_missing_title',&lt;br /&gt;
		category = 'CS1 errors: translated title',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_param_unknown_empty = {&lt;br /&gt;
		message = 'Cite has empty unknown parameter$1: $2',						-- $1 is 's' or empty space; $2 is emty unknown param list&lt;br /&gt;
		anchor = 'param_unknown_empty',&lt;br /&gt;
		category = 'CS1 errors: empty unknown parameters',&lt;br /&gt;
		hidden = true&lt;br /&gt;
		},&lt;br /&gt;
	err_vancouver = {&lt;br /&gt;
		message = 'Vancouver style error: $1',									-- $1 is error detail&lt;br /&gt;
		anchor = 'vancouver',&lt;br /&gt;
		category = 'CS1 errors: Vancouver style',&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
	err_wikilink_in_url = {&lt;br /&gt;
		message = 'URL–wikilink conflict',										-- uses ndash&lt;br /&gt;
		anchor = 'wikilink_in_url',&lt;br /&gt;
		category = 'CS1 errors: URL–wikilink conflict',							-- uses ndash&lt;br /&gt;
		hidden = false&lt;br /&gt;
		},&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; M A I N T &amp;gt;--------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
maint messages do not have a message (message = nil); otherwise the structure is the same as error messages&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
	maint_asin = {&lt;br /&gt;
		message = nil,&lt;br /&gt;
		anchor = 'ASIN',&lt;br /&gt;
		category = 'CS1 maint: ASIN uses ISBN',&lt;br /&gt;
		hidden = true,&lt;br /&gt;
		},&lt;br /&gt;
	maint_archived_copy = {&lt;br /&gt;
		message = nil,&lt;br /&gt;
		anchor = 'archived_copy',&lt;br /&gt;
		category = 'CS1 maint: archived copy as title',&lt;br /&gt;
		hidden = true,&lt;br /&gt;
		},&lt;br /&gt;
	maint_authors = {&lt;br /&gt;
		message = nil,&lt;br /&gt;
		anchor = 'authors',&lt;br /&gt;
		category = 'CS1 maint: uses authors parameter',&lt;br /&gt;
		hidden = true,&lt;br /&gt;
		},&lt;br /&gt;
	maint_bot_unknown = {&lt;br /&gt;
		message = nil,&lt;br /&gt;
		anchor = 'bot:_unknown',&lt;br /&gt;
		category = 'CS1 maint: BOT: original-url status unknown',&lt;br /&gt;
		hidden = true,&lt;br /&gt;
		},&lt;br /&gt;
	maint_date_format = {&lt;br /&gt;
		message = nil,&lt;br /&gt;
		anchor = 'date_format',&lt;br /&gt;
		category = 'CS1 maint: date format',&lt;br /&gt;
		hidden = true,&lt;br /&gt;
		},&lt;br /&gt;
	maint_date_year = {&lt;br /&gt;
		message = nil,&lt;br /&gt;
		anchor = 'date_year',&lt;br /&gt;
		category = 'CS1 maint: date and year',&lt;br /&gt;
		hidden = true,&lt;br /&gt;
		},&lt;br /&gt;
	maint_doi_ignore = {&lt;br /&gt;
		message = nil,&lt;br /&gt;
		anchor = 'doi_ignore',&lt;br /&gt;
		category = 'CS1 maint: ignored DOI errors',&lt;br /&gt;
		hidden = true,&lt;br /&gt;
		},&lt;br /&gt;
	maint_doi_inactive = {&lt;br /&gt;
		message = nil,&lt;br /&gt;
		anchor = 'doi_inactive',&lt;br /&gt;
		category = 'CS1 maint: DOI inactive',&lt;br /&gt;
		hidden = true,&lt;br /&gt;
		},&lt;br /&gt;
	maint_doi_inactive_dated = {&lt;br /&gt;
		message = nil,&lt;br /&gt;
		anchor = 'doi_inactive_dated',&lt;br /&gt;
		category = 'CS1 maint: DOI inactive as of $2$3$1',						-- $1 is year, $2 is month-name or empty string, $3 is space or empty string&lt;br /&gt;
		hidden = true,&lt;br /&gt;
		},&lt;br /&gt;
	maint_extra_punct = {&lt;br /&gt;
		message = nil,&lt;br /&gt;
		anchor = 'extra_punct',&lt;br /&gt;
		category = 'CS1 maint: extra punctuation',&lt;br /&gt;
		hidden = true,&lt;br /&gt;
		},&lt;br /&gt;
	maint_extra_text = {&lt;br /&gt;
		message = nil,&lt;br /&gt;
		anchor = 'extra_text',&lt;br /&gt;
		category = 'CS1 maint: extra text',&lt;br /&gt;
		hidden = true,&lt;br /&gt;
		},&lt;br /&gt;
	maint_extra_text_names = {&lt;br /&gt;
		message = nil,&lt;br /&gt;
		anchor = 'extra_text_names',&lt;br /&gt;
		category = 'CS1 maint: extra text: $1',									-- $1 is '&amp;lt;name&amp;gt;s list'; gets value from special_case_translation table&lt;br /&gt;
		hidden = true,&lt;br /&gt;
		},&lt;br /&gt;
	maint_isbn_ignore = {&lt;br /&gt;
		message = nil,&lt;br /&gt;
		anchor = 'ignore_isbn_err',&lt;br /&gt;
		category = 'CS1 maint: ignored ISBN errors',&lt;br /&gt;
		hidden = true,&lt;br /&gt;
		},&lt;br /&gt;
	maint_issn_ignore = {&lt;br /&gt;
		message = nil,&lt;br /&gt;
		anchor = 'ignore_issn',&lt;br /&gt;
		category = 'CS1 maint: ignored ISSN errors',&lt;br /&gt;
		hidden = true,&lt;br /&gt;
		},&lt;br /&gt;
	maint_jfm_format = {&lt;br /&gt;
		message = nil,&lt;br /&gt;
		anchor = 'jfm_format',&lt;br /&gt;
		category = 'CS1 maint: JFM format',&lt;br /&gt;
		hidden = true,&lt;br /&gt;
		},&lt;br /&gt;
	maint_location = {&lt;br /&gt;
		message = nil,&lt;br /&gt;
		anchor = 'location',&lt;br /&gt;
		category = 'CS1 maint: location',&lt;br /&gt;
		hidden = true,&lt;br /&gt;
		},&lt;br /&gt;
	maint_mr_format = {&lt;br /&gt;
		message = nil,&lt;br /&gt;
		anchor = 'mr_format',&lt;br /&gt;
		category = 'CS1 maint: MR format',&lt;br /&gt;
		hidden = true,&lt;br /&gt;
		},&lt;br /&gt;
	maint_mult_names = {&lt;br /&gt;
		message = nil,&lt;br /&gt;
		anchor = 'mult_names',&lt;br /&gt;
		category = 'CS1 maint: multiple names: $1',								-- $1 is '&amp;lt;name&amp;gt;s list'; gets value from special_case_translation table&lt;br /&gt;
		hidden = true,&lt;br /&gt;
		},&lt;br /&gt;
	maint_nocat = {&lt;br /&gt;
		message = nil,&lt;br /&gt;
		anchor = 'maint_nocat',&lt;br /&gt;
		category = 'CS1 maint: nocat',&lt;br /&gt;
		hidden = true,&lt;br /&gt;
		},&lt;br /&gt;
	maint_numeric_names = {&lt;br /&gt;
		message = nil,&lt;br /&gt;
		anchor = 'numeric_names',&lt;br /&gt;
		category = 'CS1 maint: numeric names: $1',								-- $1 is '&amp;lt;name&amp;gt;s list'; gets value from special_case_translation table&lt;br /&gt;
		hidden = true,&lt;br /&gt;
		},&lt;br /&gt;
	maint_others = {&lt;br /&gt;
		message = nil,&lt;br /&gt;
		anchor = 'others',&lt;br /&gt;
		category = 'CS1 maint: others',&lt;br /&gt;
		hidden = true,&lt;br /&gt;
		},&lt;br /&gt;
	maint_pmc_embargo = {&lt;br /&gt;
		message = nil,&lt;br /&gt;
		anchor = 'embargo',&lt;br /&gt;
		category = 'CS1 maint: PMC embargo expired',&lt;br /&gt;
		hidden = true,&lt;br /&gt;
		},&lt;br /&gt;
	maint_pmc_format = {&lt;br /&gt;
		message = nil,&lt;br /&gt;
		anchor = 'pmc_format',&lt;br /&gt;
		category = 'CS1 maint: PMC format',&lt;br /&gt;
		hidden = true,&lt;br /&gt;
		},&lt;br /&gt;
	maint_ref_harv = {&lt;br /&gt;
		message = nil,&lt;br /&gt;
		anchor = 'ref_harv',&lt;br /&gt;
		category = 'CS1 maint: ref=harv',&lt;br /&gt;
		hidden = true,&lt;br /&gt;
		},&lt;br /&gt;
	maint_unfit = {&lt;br /&gt;
		message = nil,&lt;br /&gt;
		anchor = 'unfit',&lt;br /&gt;
		category = 'CS1 maint: unfit url',&lt;br /&gt;
		hidden = true,&lt;br /&gt;
		},&lt;br /&gt;
	maint_unknown_lang = {&lt;br /&gt;
		message = nil,&lt;br /&gt;
		anchor = 'unknown_lang',&lt;br /&gt;
		category = 'CS1 maint: unrecognized language',&lt;br /&gt;
		hidden = true,&lt;br /&gt;
		},&lt;br /&gt;
	maint_untitled = {&lt;br /&gt;
		message = nil,&lt;br /&gt;
		anchor = 'untitled',&lt;br /&gt;
		category = 'CS1 maint: untitled periodical',&lt;br /&gt;
		hidden = true,&lt;br /&gt;
		},&lt;br /&gt;
	maint_zbl = {&lt;br /&gt;
		message = nil,&lt;br /&gt;
		anchor = 'zbl',&lt;br /&gt;
		category = 'CS1 maint: ZBL',&lt;br /&gt;
		hidden = true,&lt;br /&gt;
		},&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; I D _ H A N D L E R S &amp;gt;--------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
The following contains a list of values for various defined identifiers.  For each identifier we specify a&lt;br /&gt;
variety of information necessary to properly render the identifier in the citation.&lt;br /&gt;
&lt;br /&gt;
	parameters: a list of parameter aliases for this identifier; first in the list is the canonical form&lt;br /&gt;
	link: Wikipedia article name&lt;br /&gt;
	redirect: a local redirect to a local Wikipedia article name;  at en.wiki, 'ISBN (identifier)' is a redirect to 'International Standard Book Number'&lt;br /&gt;
	q: wikidata q number for the identifier&lt;br /&gt;
	label: the label preceeding the identifier; label is linked to a wikipedia article (in this order):&lt;br /&gt;
		redirect from id_handlers['&amp;lt;id&amp;gt;'].redirect when use_identifier_redirects is true&lt;br /&gt;
		wikidata-supplied article name for the local wiki from id_handlers['&amp;lt;id&amp;gt;'].q&lt;br /&gt;
		local article name from id_handlers['&amp;lt;id&amp;gt;'].link&lt;br /&gt;
	mode: 	'manual' when there is a specific function in the code to handle the identifier;&lt;br /&gt;
			'external' for identifiers that link outside of Wikipedia;&lt;br /&gt;
	prefix: the first part of a url that will be concatenated with a second part which usually contains the identifier&lt;br /&gt;
	suffix: optional third part to be added after the identifier&lt;br /&gt;
	encode: true if uri should be percent encoded; otherwise false&lt;br /&gt;
	COinS: identifier link or keyword for use in COinS:&lt;br /&gt;
		for identifiers registered at info-uri.info use: info:....&lt;br /&gt;
		for identifiers that have COinS keywords, use the keyword: rft.isbn, rft.issn, rft.eissn&lt;br /&gt;
		for others make a url using the value in prefix, use the keyword: pre (not checked; any text other than 'info' or 'rft' works here)&lt;br /&gt;
		set to nil to leave the identifier out of the COinS&lt;br /&gt;
	separator: character or text between label and the identifier in the rendered citation&lt;br /&gt;
	id_limit: for those identifiers with established limits, this property holds the upper limit&lt;br /&gt;
	access: use this parameter to set the access level for all instances of this identifier.&lt;br /&gt;
			the value must be a valid access level for an identifier (see ['id-access'] in this file).&lt;br /&gt;
	custom_access: to enable custom access level for an identifier, set this parameter&lt;br /&gt;
			to the parameter that should control it (normally 'id-access')&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local id_handlers = {&lt;br /&gt;
	['ARXIV'] = {&lt;br /&gt;
		parameters = {'arxiv', 'eprint'},&lt;br /&gt;
		link = 'arXiv',&lt;br /&gt;
		redirect = 'arXiv (identifier)',&lt;br /&gt;
		q = 'Q118398',&lt;br /&gt;
		label = 'arXiv',&lt;br /&gt;
		mode = 'manual',&lt;br /&gt;
		prefix = '//arxiv.org/abs/', 											-- protocol relative tested 2013-09-04&lt;br /&gt;
		encode = false,&lt;br /&gt;
		COinS = 'info:arxiv',&lt;br /&gt;
		separator = ':',&lt;br /&gt;
		access = 'free',														-- free to read&lt;br /&gt;
		},&lt;br /&gt;
	['ASIN'] = {&lt;br /&gt;
		parameters = { 'asin', 'ASIN' },&lt;br /&gt;
		link = 'Amazon Standard Identification Number',&lt;br /&gt;
		redirect = 'ASIN (identifier)',&lt;br /&gt;
		q = 'Q1753278',&lt;br /&gt;
		label = 'ASIN',&lt;br /&gt;
		mode = 'manual',&lt;br /&gt;
		prefix = '//www.amazon.',&lt;br /&gt;
		COinS = nil,															-- no COinS for this id (needs thinking on implementation because |asin-tld=)&lt;br /&gt;
		separator = '&amp;amp;nbsp;',&lt;br /&gt;
		encode = false;&lt;br /&gt;
		},&lt;br /&gt;
	['BIBCODE'] = {&lt;br /&gt;
		parameters = {'bibcode'},&lt;br /&gt;
		link = 'Bibcode',&lt;br /&gt;
		redirect = 'Bibcode (identifier)',&lt;br /&gt;
		q = 'Q25754',&lt;br /&gt;
		label = 'Bibcode',&lt;br /&gt;
		mode = 'manual',&lt;br /&gt;
		prefix = 'https://ui.adsabs.harvard.edu/abs/',&lt;br /&gt;
		encode = false,&lt;br /&gt;
		COinS = 'info:bibcode',&lt;br /&gt;
		separator = ':',&lt;br /&gt;
		custom_access = 'bibcode-access',&lt;br /&gt;
		},&lt;br /&gt;
	['BIORXIV'] = {&lt;br /&gt;
		parameters = {'biorxiv'},&lt;br /&gt;
		link = 'bioRxiv',&lt;br /&gt;
		redirect = 'bioRxiv (identifier)',&lt;br /&gt;
		q = 'Q19835482',&lt;br /&gt;
		label = 'bioRxiv',&lt;br /&gt;
		mode = 'manual',&lt;br /&gt;
		prefix = '//doi.org/',&lt;br /&gt;
		COinS = 'pre',															-- use prefix value&lt;br /&gt;
		access = 'free',														-- free to read&lt;br /&gt;
		encode = true,&lt;br /&gt;
		separator = '&amp;amp;nbsp;',&lt;br /&gt;
		},&lt;br /&gt;
	['CITESEERX'] = {&lt;br /&gt;
		parameters = {'citeseerx'},&lt;br /&gt;
		link = 'CiteSeerX',&lt;br /&gt;
		redirect = 'CiteSeerX (identifier)',&lt;br /&gt;
		q = 'Q2715061',&lt;br /&gt;
		label = 'CiteSeerX',&lt;br /&gt;
		mode = 'manual',														-- manual for custom validation of the &amp;quot;doi&amp;quot;&lt;br /&gt;
		prefix = '//citeseerx.ist.psu.edu/viewdoc/summary?doi=',&lt;br /&gt;
		COinS =  'pre',															-- use prefix value&lt;br /&gt;
		access = 'free',														-- free to read&lt;br /&gt;
		encode = true,&lt;br /&gt;
		separator = '&amp;amp;nbsp;',&lt;br /&gt;
		},&lt;br /&gt;
	['DOI'] = {																	-- Used by InternetArchiveBot&lt;br /&gt;
		parameters = { 'doi', 'DOI'},&lt;br /&gt;
		link = 'Digital object identifier',&lt;br /&gt;
		redirect = 'doi (identifier)',&lt;br /&gt;
		q = 'Q25670',&lt;br /&gt;
		label = 'doi',&lt;br /&gt;
		mode = 'manual',&lt;br /&gt;
		prefix = '//doi.org/',&lt;br /&gt;
		COinS = 'info:doi',&lt;br /&gt;
		separator = ':',&lt;br /&gt;
		encode = true,&lt;br /&gt;
		custom_access = 'doi-access',&lt;br /&gt;
		},&lt;br /&gt;
	['EISSN'] = {&lt;br /&gt;
		parameters = {'eissn', 'EISSN'},&lt;br /&gt;
		link = 'International_Standard_Serial_Number#Electronic_ISSN',&lt;br /&gt;
		redirect = 'eISSN (identifier)',&lt;br /&gt;
		q = 'Q46339674',&lt;br /&gt;
		label = 'eISSN',&lt;br /&gt;
		mode = 'manual',&lt;br /&gt;
		prefix = '//www.worldcat.org/issn/',&lt;br /&gt;
		COinS = 'rft.eissn',&lt;br /&gt;
		encode = false,&lt;br /&gt;
		separator = '&amp;amp;nbsp;',&lt;br /&gt;
		},&lt;br /&gt;
	['HDL'] = {&lt;br /&gt;
		parameters = { 'hdl', 'HDL' },&lt;br /&gt;
		link = 'Handle System',&lt;br /&gt;
		redirect = 'hdl (identifier)',&lt;br /&gt;
		q = 'Q3126718',&lt;br /&gt;
		label = 'hdl',&lt;br /&gt;
		mode = 'manual',&lt;br /&gt;
		prefix = '//hdl.handle.net/',&lt;br /&gt;
		COinS = 'info:hdl',&lt;br /&gt;
		separator = ':',&lt;br /&gt;
		encode = true,&lt;br /&gt;
		custom_access = 'hdl-access',&lt;br /&gt;
		},&lt;br /&gt;
	['ISBN'] = {																-- Used by InternetArchiveBot&lt;br /&gt;
		parameters = {'isbn', 'ISBN', 'isbn13', 'ISBN13'},&lt;br /&gt;
		link = 'International Standard Book Number',&lt;br /&gt;
		redirect = 'ISBN (identifier)',&lt;br /&gt;
		q = 'Q33057',&lt;br /&gt;
		label = 'ISBN',&lt;br /&gt;
		mode = 'manual',&lt;br /&gt;
		prefix = 'Special:BookSources/',&lt;br /&gt;
		COinS = 'rft.isbn',&lt;br /&gt;
		separator = '&amp;amp;nbsp;',&lt;br /&gt;
		},&lt;br /&gt;
	['ISMN'] = {&lt;br /&gt;
		parameters = {'ismn', 'ISMN'},&lt;br /&gt;
		link = 'International Standard Music Number',&lt;br /&gt;
		redirect = 'ISMN (identifier)',&lt;br /&gt;
		q = 'Q1666938',&lt;br /&gt;
		label = 'ISMN',&lt;br /&gt;
		mode = 'manual',&lt;br /&gt;
		prefix = '',															-- not currently used;&lt;br /&gt;
		COinS = 'nil',															-- nil because we can't use pre or rft or info:&lt;br /&gt;
		separator = '&amp;amp;nbsp;',&lt;br /&gt;
		},&lt;br /&gt;
	['ISSN'] = {&lt;br /&gt;
		parameters = {'issn', 'ISSN'},&lt;br /&gt;
		link = 'International Standard Serial Number',&lt;br /&gt;
		redirect = 'ISSN (identifier)',&lt;br /&gt;
		q = 'Q131276',&lt;br /&gt;
		label = 'ISSN',&lt;br /&gt;
		mode = 'manual',&lt;br /&gt;
		prefix = '//www.worldcat.org/issn/',&lt;br /&gt;
		COinS = 'rft.issn',&lt;br /&gt;
		encode = false,&lt;br /&gt;
		separator = '&amp;amp;nbsp;',&lt;br /&gt;
		},&lt;br /&gt;
	['JFM'] = {&lt;br /&gt;
		parameters = {'jfm', 'JFM'},&lt;br /&gt;
		link = 'Jahrbuch über die Fortschritte der Mathematik',&lt;br /&gt;
		redirect = 'JFM (identifier)',&lt;br /&gt;
		q = '',&lt;br /&gt;
		label = 'JFM',&lt;br /&gt;
		mode = 'manual',&lt;br /&gt;
		prefix = '//zbmath.org/?format=complete&amp;amp;q=an:',&lt;br /&gt;
		COinS = 'pre',															-- use prefix value&lt;br /&gt;
		encode = true,&lt;br /&gt;
		separator = '&amp;amp;nbsp;',&lt;br /&gt;
		},&lt;br /&gt;
	['JSTOR'] = {&lt;br /&gt;
		parameters = {'jstor', 'JSTOR'},&lt;br /&gt;
		link = 'JSTOR',&lt;br /&gt;
		redirect = 'JSTOR (identifier)',&lt;br /&gt;
		q = 'Q1420342',&lt;br /&gt;
		label = 'JSTOR',&lt;br /&gt;
		mode = 'external',&lt;br /&gt;
		prefix = '//www.jstor.org/stable/', 									-- protocol relative tested 2013-09-04&lt;br /&gt;
		COinS = 'pre',															-- use prefix value&lt;br /&gt;
		encode = false,&lt;br /&gt;
		separator = '&amp;amp;nbsp;',&lt;br /&gt;
		custom_access = 'jstor-access',&lt;br /&gt;
		},&lt;br /&gt;
	['LCCN'] = {&lt;br /&gt;
		parameters = {'lccn', 'LCCN'},&lt;br /&gt;
		link = 'Library of Congress Control Number',&lt;br /&gt;
		redirect = 'LCCN (identifier)',&lt;br /&gt;
		q = 'Q620946',&lt;br /&gt;
		label = 'LCCN',&lt;br /&gt;
		mode = 'manual',&lt;br /&gt;
		prefix = '//lccn.loc.gov/', 											-- protocol relative tested 2015-12-28&lt;br /&gt;
		COinS = 'info:lccn',&lt;br /&gt;
		encode = false,&lt;br /&gt;
		separator = '&amp;amp;nbsp;',&lt;br /&gt;
		},&lt;br /&gt;
	['MR'] = {&lt;br /&gt;
		parameters = {'mr', 'MR'},&lt;br /&gt;
		link = 'Mathematical Reviews',&lt;br /&gt;
		redirect = 'MR (identifier)',&lt;br /&gt;
		q = 'Q211172',&lt;br /&gt;
		label = 'MR',&lt;br /&gt;
		mode = 'manual',&lt;br /&gt;
		prefix = '//www.ams.org/mathscinet-getitem?mr=', 						-- protocol relative tested 2013-09-04&lt;br /&gt;
		COinS = 'pre',															-- use prefix value&lt;br /&gt;
		encode = true,&lt;br /&gt;
		separator = '&amp;amp;nbsp;',&lt;br /&gt;
		},&lt;br /&gt;
	['OCLC'] = {&lt;br /&gt;
		parameters = {'oclc', 'OCLC'},&lt;br /&gt;
		link = 'OCLC',&lt;br /&gt;
		redirect = 'OCLC (identifier)',&lt;br /&gt;
		q = 'Q190593',&lt;br /&gt;
		label = 'OCLC',&lt;br /&gt;
		mode = 'manual',&lt;br /&gt;
		prefix = '//www.worldcat.org/oclc/',&lt;br /&gt;
		COinS = 'info:oclcnum',&lt;br /&gt;
		encode = true,&lt;br /&gt;
		separator = '&amp;amp;nbsp;',&lt;br /&gt;
		},&lt;br /&gt;
	['OL'] = {&lt;br /&gt;
		parameters = { 'ol', 'OL' },&lt;br /&gt;
		link = 'Open Library',&lt;br /&gt;
		redirect = 'OL (identifier)',&lt;br /&gt;
		q = 'Q1201876',&lt;br /&gt;
		label = 'OL',&lt;br /&gt;
		mode = 'manual',&lt;br /&gt;
		prefix = '//openlibrary.org/',&lt;br /&gt;
		COinS = nil,															-- no COinS for this id (needs thinking on implementation because /authors/books/works/OL)&lt;br /&gt;
		separator = '&amp;amp;nbsp;',&lt;br /&gt;
		encode = true,&lt;br /&gt;
		custom_access = 'ol-access',&lt;br /&gt;
		},&lt;br /&gt;
	['OSTI'] = {&lt;br /&gt;
		parameters = {'osti', 'OSTI'},&lt;br /&gt;
		link = 'Office of Scientific and Technical Information',&lt;br /&gt;
		redirect = 'OSTI (identifier)',&lt;br /&gt;
		q = 'Q2015776',&lt;br /&gt;
		label = 'OSTI',&lt;br /&gt;
		mode = 'external',&lt;br /&gt;
		prefix = '//www.osti.gov/biblio/',										-- protocol relative tested 2018-09-12&lt;br /&gt;
		COinS = 'pre',															-- use prefix value&lt;br /&gt;
		encode = true,&lt;br /&gt;
		separator = '&amp;amp;nbsp;',&lt;br /&gt;
		custom_access = 'osti-access',&lt;br /&gt;
		},&lt;br /&gt;
	['PMC'] = {&lt;br /&gt;
		parameters = {'pmc', 'PMC'},&lt;br /&gt;
		link = 'PubMed Central',&lt;br /&gt;
		redirect = 'PMC (identifier)',&lt;br /&gt;
		q = 'Q229883',&lt;br /&gt;
		label = 'PMC',&lt;br /&gt;
		mode = 'manual',&lt;br /&gt;
		prefix = '//www.ncbi.nlm.nih.gov/pmc/articles/PMC',&lt;br /&gt;
		suffix = &amp;quot; &amp;quot;,&lt;br /&gt;
		COinS = 'pre',															-- use prefix value&lt;br /&gt;
		encode = true,&lt;br /&gt;
		separator = '&amp;amp;nbsp;',&lt;br /&gt;
		id_limit = 8000000,&lt;br /&gt;
		access = 'free',														-- free to read&lt;br /&gt;
		},&lt;br /&gt;
	['PMID'] = {&lt;br /&gt;
		parameters = {'pmid', 'PMID'},&lt;br /&gt;
		link = 'PubMed Identifier',&lt;br /&gt;
		redirect = 'PMID (identifier)',&lt;br /&gt;
		q = '',&lt;br /&gt;
		label = 'PMID',&lt;br /&gt;
		mode = 'manual',&lt;br /&gt;
		prefix = '//pubmed.ncbi.nlm.nih.gov/',&lt;br /&gt;
		COinS = 'info:pmid',&lt;br /&gt;
		encode = false,&lt;br /&gt;
		separator = '&amp;amp;nbsp;',&lt;br /&gt;
		id_limit = 50000000,&lt;br /&gt;
		},&lt;br /&gt;
	['RFC'] = {&lt;br /&gt;
		parameters = {'rfc', 'RFC'},&lt;br /&gt;
		link = 'Request for Comments',&lt;br /&gt;
		redirect = 'RFC (identifier)',&lt;br /&gt;
		q = 'Q212971',&lt;br /&gt;
		label = 'RFC',&lt;br /&gt;
		mode = 'external',&lt;br /&gt;
		prefix = '//tools.ietf.org/html/rfc',&lt;br /&gt;
		COinS = 'pre',															-- use prefix value&lt;br /&gt;
		encode = false,&lt;br /&gt;
		separator = '&amp;amp;nbsp;',&lt;br /&gt;
		access = 'free',														-- free to read&lt;br /&gt;
		},&lt;br /&gt;
	['SBN'] = {&lt;br /&gt;
		parameters = {'sbn', 'SBN'},&lt;br /&gt;
		link = 'Standard Book Number',											-- redirect to International_Standard_Book_Number#History&lt;br /&gt;
		redirect = 'SBN (identifier)',&lt;br /&gt;
		label = 'SBN',&lt;br /&gt;
		mode = 'manual',&lt;br /&gt;
		prefix = 'Special:BookSources/0-',										-- prefix has leading zero necessary to make 9-digit sbn a 10-digit isbn&lt;br /&gt;
		COinS = nil,															-- nil because we can't use pre or rft or info:&lt;br /&gt;
		separator = '&amp;amp;nbsp;',&lt;br /&gt;
		},&lt;br /&gt;
	['SSRN'] = {&lt;br /&gt;
		parameters = {'ssrn', 'SSRN'},&lt;br /&gt;
		link = 'Social Science Research Network',&lt;br /&gt;
		redirect = 'SSRN (identifier)',&lt;br /&gt;
		q = 'Q7550801',&lt;br /&gt;
		label = 'SSRN',&lt;br /&gt;
		mode = 'manual',&lt;br /&gt;
		prefix = '//ssrn.com/abstract=', 										-- protocol relative tested 2013-09-04&lt;br /&gt;
		COinS = 'pre',															-- use prefix value&lt;br /&gt;
		encode = true,&lt;br /&gt;
		separator = '&amp;amp;nbsp;',&lt;br /&gt;
		id_limit = 4000000,&lt;br /&gt;
		access = 'free',														-- always free to read&lt;br /&gt;
		},&lt;br /&gt;
	['S2CID'] = {&lt;br /&gt;
		parameters = {'s2cid', 'S2CID'},&lt;br /&gt;
		link = 'Semantic Scholar',&lt;br /&gt;
		redirect = 'S2CID (identifier)',&lt;br /&gt;
		q = 'Q22908627',&lt;br /&gt;
		label = 'S2CID',&lt;br /&gt;
		mode = 'manual',&lt;br /&gt;
		prefix = 'https://api.semanticscholar.org/CorpusID:',&lt;br /&gt;
		COinS = 'pre',															-- use prefix value&lt;br /&gt;
		encode = false,&lt;br /&gt;
		separator = '&amp;amp;nbsp;',&lt;br /&gt;
		id_limit = 230000000,&lt;br /&gt;
		custom_access = 's2cid-access',&lt;br /&gt;
		},&lt;br /&gt;
	['USENETID'] = {&lt;br /&gt;
		parameters = {'message-id'},&lt;br /&gt;
		link = 'Usenet',&lt;br /&gt;
		redirect = 'Usenet (identifier)',&lt;br /&gt;
		q = 'Q193162',&lt;br /&gt;
		label = 'Usenet:',&lt;br /&gt;
		mode = 'manual',&lt;br /&gt;
		prefix = 'news:',&lt;br /&gt;
		encode = false,&lt;br /&gt;
		COinS = 'pre',															-- use prefix value&lt;br /&gt;
		separator = '&amp;amp;nbsp;',&lt;br /&gt;
		},&lt;br /&gt;
	['ZBL'] = {&lt;br /&gt;
		parameters = {'zbl', 'ZBL' },&lt;br /&gt;
		link = 'Zentralblatt MATH',&lt;br /&gt;
		redirect = 'Zbl (identifier)',&lt;br /&gt;
		q = 'Q190269',&lt;br /&gt;
		label = 'Zbl',&lt;br /&gt;
		mode = 'manual',&lt;br /&gt;
		prefix = '//zbmath.org/?format=complete&amp;amp;q=an:',&lt;br /&gt;
		COinS = 'pre',															-- use prefix value&lt;br /&gt;
		encode = true,&lt;br /&gt;
		separator = '&amp;amp;nbsp;',&lt;br /&gt;
		},&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; E X P O R T S &amp;gt;----------------------------------------------------------------&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
return 	{&lt;br /&gt;
	use_identifier_redirects = true,											-- when true use redirect name for identifier label links&lt;br /&gt;
&lt;br /&gt;
	aliases = aliases,&lt;br /&gt;
	special_case_translation = special_case_translation,&lt;br /&gt;
	date_names = date_names,&lt;br /&gt;
	err_msg_supl = err_msg_supl,&lt;br /&gt;
	error_conditions = error_conditions,&lt;br /&gt;
	editor_markup_patterns = editor_markup_patterns,&lt;br /&gt;
	et_al_patterns = et_al_patterns,&lt;br /&gt;
	global_df = global_df,&lt;br /&gt;
	id_handlers = id_handlers,&lt;br /&gt;
	keywords_lists = keywords_lists,&lt;br /&gt;
	keywords_xlate = keywords_xlate,&lt;br /&gt;
	stripmarkers=stripmarkers,&lt;br /&gt;
	invisible_chars = invisible_chars,&lt;br /&gt;
	indic_script = indic_script,&lt;br /&gt;
	local_lang_cat_enable = local_lang_cat_enable,&lt;br /&gt;
	maint_cats = maint_cats,&lt;br /&gt;
	messages = messages,&lt;br /&gt;
	presentation = presentation,&lt;br /&gt;
	prop_cats = prop_cats,&lt;br /&gt;
	punct_skip = punct_skip,&lt;br /&gt;
	script_lang_codes = script_lang_codes,&lt;br /&gt;
	lang_code_remap = lang_code_remap,&lt;br /&gt;
	lang_name_remap = lang_name_remap,&lt;br /&gt;
	this_wiki_code = this_wiki_code,&lt;br /&gt;
	title_types = title_types,&lt;br /&gt;
	uncategorized_namespaces = uncategorized_namespaces,&lt;br /&gt;
	uncategorized_subpages = uncategorized_subpages,&lt;br /&gt;
	templates_using_volume = templates_using_volume,&lt;br /&gt;
	templates_using_issue = templates_using_issue,&lt;br /&gt;
	templates_not_using_page = templates_not_using_page,&lt;br /&gt;
	&lt;br /&gt;
	inter_wiki_map = inter_wiki_map,&lt;br /&gt;
	languages = languages,&lt;br /&gt;
	}&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Test2&amp;diff=627</id>
		<title>Test2</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Test2&amp;diff=627"/>
		<updated>2020-10-29T11:26:30Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a test. Hooray!!!&amp;lt;ref&amp;gt;{{Cite journal|last=Rishel|first=Chris A.|last2=Zhang|first2=Yuting|last3=Sun|first3=Eric C.|date=2020-10-01|title=Association Between Preoperative Benzodiazepine Use and Postoperative Opioid Use and Health Care Costs|url=https://pubmed.ncbi.nlm.nih.gov/33107919/|journal=JAMA network open|volume=3|issue=10|pages=e2018761|doi=10.1001/jamanetworkopen.2020.18761|issn=2574-3805|pmid=33107919}}&amp;lt;/ref&amp;gt;&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=626</id>
		<title>Main Page</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=626"/>
		<updated>2020-10-29T11:24:11Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;strong&amp;gt;MediaWiki has been installed.&amp;lt;/strong&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Consult the [[mediawikiwiki:Special:MyLanguage/Help:Contents|User's Guide]] for information on using the wiki software. Hooray!!!&lt;br /&gt;
&lt;br /&gt;
== Getting started ==&lt;br /&gt;
&lt;br /&gt;
* [[mediawikiwiki:Special:MyLanguage/Manual:Configuration_settings|Configuration settings list]]&lt;br /&gt;
* [[mediawikiwiki:Special:MyLanguage/Manual:FAQ|MediaWiki FAQ]]&lt;br /&gt;
* [https://lists.wikimedia.org/mailman/listinfo/mediawiki-announce MediaWiki release mailing list]&lt;br /&gt;
* [[mediawikiwiki:Special:MyLanguage/Localisation#Translation_resources|Localise MediaWiki for your language]]&lt;br /&gt;
* [[mediawikiwiki:Special:MyLanguage/Manual:Combating_spam|Learn how to combat spam on your wiki]]&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=625</id>
		<title>Main Page</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=625"/>
		<updated>2020-10-29T11:23:59Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;strong&amp;gt;MediaWiki has been installed.&amp;lt;/strong&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Consult the [[mediawikiwiki:Special:MyLanguage/Help:Contents|User's Guide]] for information on using the wiki software. Hooray!!&lt;br /&gt;
&lt;br /&gt;
== Getting started ==&lt;br /&gt;
&lt;br /&gt;
* [[mediawikiwiki:Special:MyLanguage/Manual:Configuration_settings|Configuration settings list]]&lt;br /&gt;
* [[mediawikiwiki:Special:MyLanguage/Manual:FAQ|MediaWiki FAQ]]&lt;br /&gt;
* [https://lists.wikimedia.org/mailman/listinfo/mediawiki-announce MediaWiki release mailing list]&lt;br /&gt;
* [[mediawikiwiki:Special:MyLanguage/Localisation#Translation_resources|Localise MediaWiki for your language]]&lt;br /&gt;
* [[mediawikiwiki:Special:MyLanguage/Manual:Combating_spam|Learn how to combat spam on your wiki]]&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Test2&amp;diff=624</id>
		<title>Test2</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Test2&amp;diff=624"/>
		<updated>2020-10-29T11:03:33Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a test. Hooray!&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=623</id>
		<title>Main Page</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Main_Page&amp;diff=623"/>
		<updated>2020-10-29T10:59:44Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;strong&amp;gt;MediaWiki has been installed.&amp;lt;/strong&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Consult the [[mediawikiwiki:Special:MyLanguage/Help:Contents|User's Guide]] for information on using the wiki software. Hooray!&lt;br /&gt;
&lt;br /&gt;
== Getting started ==&lt;br /&gt;
&lt;br /&gt;
* [[mediawikiwiki:Special:MyLanguage/Manual:Configuration_settings|Configuration settings list]]&lt;br /&gt;
* [[mediawikiwiki:Special:MyLanguage/Manual:FAQ|MediaWiki FAQ]]&lt;br /&gt;
* [https://lists.wikimedia.org/mailman/listinfo/mediawiki-announce MediaWiki release mailing list]&lt;br /&gt;
* [[mediawikiwiki:Special:MyLanguage/Localisation#Translation_resources|Localise MediaWiki for your language]]&lt;br /&gt;
* [[mediawikiwiki:Special:MyLanguage/Manual:Combating_spam|Learn how to combat spam on your wiki]]&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Test2&amp;diff=622</id>
		<title>Test2</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Test2&amp;diff=622"/>
		<updated>2020-10-29T04:13:12Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: Created page with &amp;quot;This is a test&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a test&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Module:Citation/CS1/styles.css&amp;diff=621</id>
		<title>Module:Citation/CS1/styles.css</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Module:Citation/CS1/styles.css&amp;diff=621"/>
		<updated>2020-10-29T03:45:05Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: 1 revision imported&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;/* Protection icon&lt;br /&gt;
the following line controls the page-protection icon in the upper right corner&lt;br /&gt;
it must remain within this comment&lt;br /&gt;
	{{sandbox other||{{pp-template}}}}&lt;br /&gt;
&lt;br /&gt;
*/&lt;br /&gt;
&lt;br /&gt;
/* Overrides&lt;br /&gt;
Some wikis do not override user agent default styles for HTML &amp;lt;cite&amp;gt; and &amp;lt;q&amp;gt;,&lt;br /&gt;
unlike en.wp. On en.wp, keep these the same as [[MediaWiki:Common.css]]&lt;br /&gt;
*/&lt;br /&gt;
cite.citation {&lt;br /&gt;
	font-style: inherit; /* Remove italics for &amp;lt;cite&amp;gt; */&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
.citation q {&lt;br /&gt;
	quotes: '&amp;quot;' '&amp;quot;' &amp;quot;'&amp;quot; &amp;quot;'&amp;quot;; /* Straight quote marks for &amp;lt;q&amp;gt; */&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/* ID and URL access&lt;br /&gt;
Both core and Common.css have selector .mw-parser-output a[href$=&amp;quot;.pdf&amp;quot;].external&lt;br /&gt;
for PDF pages. All TemplateStyles pages are hoisted to .mw-parser-output. We need&lt;br /&gt;
to have specificity equal to a[href$=&amp;quot;.pdf&amp;quot;].external for locks to override PDF icon.&lt;br /&gt;
&lt;br /&gt;
the .id-lock-... selectors are for use by non-citation templates like {{Catalog lookup link}}&lt;br /&gt;
*/&lt;br /&gt;
.id-lock-free a,&lt;br /&gt;
.citation .cs1-lock-free a {&lt;br /&gt;
	background: linear-gradient(transparent, transparent),&lt;br /&gt;
		url(//upload.wikimedia.org/wikipedia/commons/6/65/Lock-green.svg)&lt;br /&gt;
		right 0.1em center/9px no-repeat;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
.id-lock-limited a,&lt;br /&gt;
.id-lock-registration a,&lt;br /&gt;
.citation .cs1-lock-limited a,&lt;br /&gt;
.citation .cs1-lock-registration a {&lt;br /&gt;
	background: linear-gradient(transparent, transparent),&lt;br /&gt;
		url(//upload.wikimedia.org/wikipedia/commons/d/d6/Lock-gray-alt-2.svg)&lt;br /&gt;
		right 0.1em center/9px no-repeat;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
.id-lock-subscription a,&lt;br /&gt;
.citation .cs1-lock-subscription a {&lt;br /&gt;
	background: linear-gradient(transparent, transparent),&lt;br /&gt;
		url(//upload.wikimedia.org/wikipedia/commons/a/aa/Lock-red-alt-2.svg)&lt;br /&gt;
		right 0.1em center/9px no-repeat;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
.cs1-subscription,&lt;br /&gt;
.cs1-registration {&lt;br /&gt;
	color: #555;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
.cs1-subscription span,&lt;br /&gt;
.cs1-registration span {&lt;br /&gt;
	border-bottom: 1px dotted;&lt;br /&gt;
	cursor: help;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/* Wikisource&lt;br /&gt;
Wikisource icon when |chapter= or |title= is wikilinked to Wikisource&lt;br /&gt;
as in cite wikisource&lt;br /&gt;
*/&lt;br /&gt;
.cs1-ws-icon a {&lt;br /&gt;
	background: linear-gradient(transparent, transparent),&lt;br /&gt;
		url(//upload.wikimedia.org/wikipedia/commons/4/4c/Wikisource-logo.svg)&lt;br /&gt;
		right 0.1em center/12px no-repeat;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/* Errors and maintenance */&lt;br /&gt;
code.cs1-code {&lt;br /&gt;
	/* &amp;lt;code&amp;gt;...&amp;lt;/code&amp;gt; style override: mediawiki's css definition is specified here:&lt;br /&gt;
	https://git.wikimedia.org/blob/mediawiki%2Fcore.git/&lt;br /&gt;
		69cd73811f7aadd093050dbf20ed70ef0b42a713/skins%2Fcommon%2FcommonElements.css#L199&lt;br /&gt;
	*/&lt;br /&gt;
	color: inherit;&lt;br /&gt;
	background: inherit;&lt;br /&gt;
	border: none; /* this maybe can be inherit. MDN says yes, code editor says no */&lt;br /&gt;
	padding: inherit;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
.cs1-hidden-error {&lt;br /&gt;
	display: none;&lt;br /&gt;
	font-size: 100%;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
.cs1-visible-error {&lt;br /&gt;
	font-size: 100%;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
.cs1-maint {&lt;br /&gt;
	display: none;&lt;br /&gt;
	color: #33aa33;&lt;br /&gt;
	margin-left: 0.3em;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/* Small text size&lt;br /&gt;
Set small text size in one place. 0.95 (here) * 0.9 (from references list) is&lt;br /&gt;
~0.85, which is the lower bound for size for accessibility. Old styling for this&lt;br /&gt;
was just 0.85. We could write the rule so that when this template is inside&lt;br /&gt;
references/reflist, only then does it multiply by 0.95; else multiply by 0.85 */&lt;br /&gt;
.cs1-subscription,&lt;br /&gt;
.cs1-registration,&lt;br /&gt;
.cs1-format {&lt;br /&gt;
	font-size: 95%;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/* kerning */&lt;br /&gt;
.cs1-kern-left,&lt;br /&gt;
.cs1-kern-wl-left {&lt;br /&gt;
	padding-left: 0.2em;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
.cs1-kern-right,&lt;br /&gt;
.cs1-kern-wl-right {&lt;br /&gt;
	padding-right: 0.2em;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/* selflinks – avoid bold font style when cs1|2 template links to the current page */&lt;br /&gt;
.citation .mw-selflink {&lt;br /&gt;
	font-weight: inherit;&lt;br /&gt;
}&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Module:Citation/CS1&amp;diff=619</id>
		<title>Module:Citation/CS1</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Module:Citation/CS1&amp;diff=619"/>
		<updated>2020-10-29T03:44:38Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: 1 revision imported&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
require('Module:No globals');&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; F O R W A R D   D E C L A R A T I O N S &amp;gt;--------------------------------------&lt;br /&gt;
&lt;br /&gt;
each of these counts against the Lua upvalue limit&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local validation;																-- functions in Module:Citation/CS1/Date_validation&lt;br /&gt;
&lt;br /&gt;
local utilities;																-- functions in Module:Citation/CS1/Utilities&lt;br /&gt;
local z ={};																	-- table of tables in Module:Citation/CS1/Utilities&lt;br /&gt;
&lt;br /&gt;
local identifiers;																-- functions and tables in Module:Citation/CS1/Identifiers&lt;br /&gt;
local metadata;																	-- functions in Module:Citation/CS1/COinS&lt;br /&gt;
local cfg = {};																	-- table of configuration tables that are defined in Module:Citation/CS1/Configuration&lt;br /&gt;
local whitelist = {};															-- table of tables listing valid template parameter names; defined in Module:Citation/CS1/Whitelist&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; P A G E   S C O P E   V A R I A B L E S &amp;gt;--------------------------------------&lt;br /&gt;
&lt;br /&gt;
declare variables here that have page-wide scope that are not brought in from other modules; that are created here and used here&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local added_deprecated_cat;														-- Boolean flag so that the category is added only once&lt;br /&gt;
local added_vanc_errs;															-- Boolean flag so we only emit one Vancouver error / category&lt;br /&gt;
&lt;br /&gt;
local Frame;																	-- holds the module's frame table&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; F I R S T _ S E T &amp;gt;------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Locates and returns the first set value in a table of values where the order established in the table,&lt;br /&gt;
left-to-right (or top-to-bottom), is the order in which the values are evaluated.  Returns nil if none are set.&lt;br /&gt;
&lt;br /&gt;
This version replaces the original 'for _, val in pairs do' and a similar version that used ipairs.  With the pairs&lt;br /&gt;
version the order of evaluation could not be guaranteed.  With the ipairs version, a nil value would terminate&lt;br /&gt;
the for-loop before it reached the actual end of the list.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function first_set (list, count)&lt;br /&gt;
	local i = 1;&lt;br /&gt;
	while i &amp;lt;= count do															-- loop through all items in list&lt;br /&gt;
		if utilities.is_set( list[i] ) then&lt;br /&gt;
			return list[i];														-- return the first set list member&lt;br /&gt;
		end&lt;br /&gt;
		i = i + 1;																-- point to next&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; A D D _ V A N C _ E R R O R &amp;gt;----------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Adds a single Vancouver system error message to the template's output regardless of how many error actually exist.&lt;br /&gt;
To prevent duplication, added_vanc_errs is nil until an error message is emitted.&lt;br /&gt;
&lt;br /&gt;
added_vanc_errs is a Boolean declared in page scope variables above&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function add_vanc_error (source)&lt;br /&gt;
	if not added_vanc_errs then&lt;br /&gt;
		added_vanc_errs = true;													-- note that we've added this category&lt;br /&gt;
		table.insert( z.message_tail, { utilities.set_message ( 'err_vancouver', {source}, true ) } );&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; I S _ S C H E M E &amp;gt;------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
does this thing that purports to be a URI scheme seem to be a valid scheme?  The scheme is checked to see if it&lt;br /&gt;
is in agreement with http://tools.ietf.org/html/std66#section-3.1 which says:&lt;br /&gt;
	Scheme names consist of a sequence of characters beginning with a&lt;br /&gt;
   letter and followed by any combination of letters, digits, plus&lt;br /&gt;
   (&amp;quot;+&amp;quot;), period (&amp;quot;.&amp;quot;), or hyphen (&amp;quot;-&amp;quot;).&lt;br /&gt;
&lt;br /&gt;
returns true if it does, else false&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function is_scheme (scheme)&lt;br /&gt;
	return scheme and scheme:match ('^%a[%a%d%+%.%-]*:');						-- true if scheme is set and matches the pattern&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[=[-------------------------&amp;lt; I S _ D O M A I N _ N A M E &amp;gt;--------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Does this thing that purports to be a domain name seem to be a valid domain name?&lt;br /&gt;
&lt;br /&gt;
Syntax defined here: http://tools.ietf.org/html/rfc1034#section-3.5&lt;br /&gt;
BNF defined here: https://tools.ietf.org/html/rfc4234&lt;br /&gt;
Single character names are generally reserved; see https://tools.ietf.org/html/draft-ietf-dnsind-iana-dns-01#page-15;&lt;br /&gt;
	see also [[Single-letter second-level domain]]&lt;br /&gt;
list of TLDs: https://www.iana.org/domains/root/db&lt;br /&gt;
&lt;br /&gt;
RFC 952 (modified by RFC 1123) requires the first and last character of a hostname to be a letter or a digit.  Between&lt;br /&gt;
the first and last characters the name may use letters, digits, and the hyphen.&lt;br /&gt;
&lt;br /&gt;
Also allowed are IPv4 addresses. IPv6 not supported&lt;br /&gt;
&lt;br /&gt;
domain is expected to be stripped of any path so that the last character in the last character of the TLD.  tld&lt;br /&gt;
is two or more alpha characters.  Any preceding '//' (from splitting a URL with a scheme) will be stripped&lt;br /&gt;
here.  Perhaps not necessary but retained in case it is necessary for IPv4 dot decimal.&lt;br /&gt;
&lt;br /&gt;
There are several tests:&lt;br /&gt;
	the first character of the whole domain name including subdomains must be a letter or a digit&lt;br /&gt;
	internationalized domain name (ASCII characters with .xn-- ASCII Compatible Encoding (ACE) prefix xn-- in the TLD) see https://tools.ietf.org/html/rfc3490&lt;br /&gt;
	single-letter/digit second-level domains in the .org, .cash, and .today TLDs&lt;br /&gt;
	q, x, and z SL domains in the .com TLD&lt;br /&gt;
	i and q SL domains in the .net TLD&lt;br /&gt;
	single-letter SL domains in the ccTLDs (where the ccTLD is two letters)&lt;br /&gt;
	two-character SL domains in gTLDs (where the gTLD is two or more letters)&lt;br /&gt;
	three-plus-character SL domains in gTLDs (where the gTLD is two or more letters)&lt;br /&gt;
	IPv4 dot-decimal address format; TLD not allowed&lt;br /&gt;
&lt;br /&gt;
returns true if domain appears to be a proper name and TLD or IPv4 address, else false&lt;br /&gt;
&lt;br /&gt;
]=]&lt;br /&gt;
&lt;br /&gt;
local function is_domain_name (domain)&lt;br /&gt;
	if not domain then&lt;br /&gt;
		return false;															-- if not set, abandon&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	domain = domain:gsub ('^//', '');											-- strip '//' from domain name if present; done here so we only have to do it once&lt;br /&gt;
	&lt;br /&gt;
	if not domain:match ('^[%w]') then											-- first character must be letter or digit&lt;br /&gt;
		return false;&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if domain:match ('^%a+:') then												-- hack to detect things that look like s:Page:Title where Page: is namespace at Wikisource&lt;br /&gt;
		return false;&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local patterns = {															-- patterns that look like URLs&lt;br /&gt;
		'%f[%w][%w][%w%-]+[%w]%.%a%a+$',										-- three or more character hostname.hostname or hostname.tld&lt;br /&gt;
		'%f[%w][%w][%w%-]+[%w]%.xn%-%-[%w]+$',									-- internationalized domain name with ACE prefix&lt;br /&gt;
		'%f[%a][qxz]%.com$',													-- assigned one character .com hostname (x.com times out 2015-12-10)&lt;br /&gt;
		'%f[%a][iq]%.net$',														-- assigned one character .net hostname (q.net registered but not active 2015-12-10)&lt;br /&gt;
		'%f[%w][%w]%.%a%a$',													-- one character hostname and ccTLD (2 chars)&lt;br /&gt;
		'%f[%w][%w][%w]%.%a%a+$',												-- two character hostname and TLD&lt;br /&gt;
		'^%d%d?%d?%.%d%d?%d?%.%d%d?%d?%.%d%d?%d?',								-- IPv4 address&lt;br /&gt;
		}&lt;br /&gt;
&lt;br /&gt;
	for _, pattern in ipairs (patterns) do										-- loop through the patterns list&lt;br /&gt;
		if domain:match (pattern) then&lt;br /&gt;
			return true;														-- if a match then we think that this thing that purports to be a URL is a URL&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	for _, d in ipairs ({'cash', 'company', 'today', 'org'}) do					-- look for single letter second level domain names for these top level domains&lt;br /&gt;
		if domain:match ('%f[%w][%w]%.' .. d) then&lt;br /&gt;
			return true&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	return false;																-- no matches, we don't know what this thing is&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; I S _ U R L &amp;gt;------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
returns true if the scheme and domain parts of a URL appear to be a valid URL; else false.&lt;br /&gt;
&lt;br /&gt;
This function is the last step in the validation process.  This function is separate because there are cases that&lt;br /&gt;
are not covered by split_url(), for example is_parameter_ext_wikilink() which is looking for bracketted external&lt;br /&gt;
wikilinks.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function is_url (scheme, domain)&lt;br /&gt;
	if utilities.is_set (scheme) then											-- if scheme is set check it and domain&lt;br /&gt;
		return is_scheme (scheme) and is_domain_name (domain);&lt;br /&gt;
	else&lt;br /&gt;
		return is_domain_name (domain);											-- scheme not set when URL is protocol-relative&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; S P L I T _ U R L &amp;gt;------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Split a URL into a scheme, authority indicator, and domain.&lt;br /&gt;
&lt;br /&gt;
First remove Fully Qualified Domain Name terminator (a dot following TLD) (if any) and any path(/), query(?) or fragment(#).&lt;br /&gt;
&lt;br /&gt;
If protocol-relative URL, return nil scheme and domain else return nil for both scheme and domain.&lt;br /&gt;
&lt;br /&gt;
When not protocol-relative, get scheme, authority indicator, and domain.  If there is an authority indicator (one&lt;br /&gt;
or more '/' characters immediately following the scheme's colon), make sure that there are only 2.&lt;br /&gt;
&lt;br /&gt;
Any URL that does not have news: scheme must have authority indicator (//).  TODO: are there other common schemes&lt;br /&gt;
like news: that don't use authority indicator?&lt;br /&gt;
&lt;br /&gt;
Strip off any port and path;&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function split_url (url_str)&lt;br /&gt;
	local scheme, authority, domain;&lt;br /&gt;
	&lt;br /&gt;
	url_str = url_str:gsub ('([%a%d])%.?[/%?#].*$', '%1');						-- strip FQDN terminator and path(/), query(?), fragment (#) (the capture prevents false replacement of '//')&lt;br /&gt;
&lt;br /&gt;
	if url_str:match ('^//%S*') then											-- if there is what appears to be a protocol-relative URL&lt;br /&gt;
		domain = url_str:match ('^//(%S*)')&lt;br /&gt;
	elseif url_str:match ('%S-:/*%S+') then										-- if there is what appears to be a scheme, optional authority indicator, and domain name&lt;br /&gt;
		scheme, authority, domain = url_str:match ('(%S-:)(/*)(%S+)');			-- extract the scheme, authority indicator, and domain portions&lt;br /&gt;
		if utilities.is_set (authority) then&lt;br /&gt;
			authority = authority:gsub ('//', '', 1);							-- replace place 1 pair of '/' with nothing;&lt;br /&gt;
			if utilities.is_set(authority) then									-- if anything left (1 or 3+ '/' where authority should be) then&lt;br /&gt;
				return scheme;													-- return scheme only making domain nil which will cause an error message&lt;br /&gt;
			end&lt;br /&gt;
		else&lt;br /&gt;
			if not scheme:match ('^news:') then									-- except for news:..., MediaWiki won't link URLs that do not have authority indicator; TODO: a better way to do this test?&lt;br /&gt;
				return scheme;													-- return scheme only making domain nil which will cause an error message&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
		domain = domain:gsub ('(%a):%d+', '%1');								-- strip port number if present&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	return scheme, domain;&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; L I N K _ P A R A M _ O K &amp;gt;---------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
checks the content of |title-link=, |series-link=, |author-link=, etc. for properly formatted content: no wikilinks, no URLs&lt;br /&gt;
&lt;br /&gt;
Link parameters are to hold the title of a Wikipedia article, so none of the WP:TITLESPECIALCHARACTERS are allowed:&lt;br /&gt;
	# &amp;lt; &amp;gt; [ ] | { } _&lt;br /&gt;
except the underscore which is used as a space in wiki URLs and # which is used for section links&lt;br /&gt;
&lt;br /&gt;
returns false when the value contains any of these characters.&lt;br /&gt;
&lt;br /&gt;
When there are no illegal characters, this function returns TRUE if value DOES NOT appear to be a valid URL (the&lt;br /&gt;
|&amp;lt;param&amp;gt;-link= parameter is ok); else false when value appears to be a valid URL (the |&amp;lt;param&amp;gt;-link= parameter is NOT ok).&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function link_param_ok (value)&lt;br /&gt;
	local scheme, domain;&lt;br /&gt;
	if value:find ('[&amp;lt;&amp;gt;%[%]|{}]') then											-- if any prohibited characters&lt;br /&gt;
		return false;&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	scheme, domain = split_url (value);											-- get scheme or nil and domain or nil from URL; &lt;br /&gt;
	return not is_url (scheme, domain);											-- return true if value DOES NOT appear to be a valid URL&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; L I N K _ T I T L E _ O K &amp;gt;---------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Use link_param_ok() to validate |&amp;lt;param&amp;gt;-link= value and its matching |&amp;lt;title&amp;gt;= value.&lt;br /&gt;
&lt;br /&gt;
|&amp;lt;title&amp;gt;= may be wiki-linked but not when |&amp;lt;param&amp;gt;-link= has a value.  This function emits an error message when&lt;br /&gt;
that condition exists&lt;br /&gt;
&lt;br /&gt;
check &amp;lt;link&amp;gt; for inter-language interwiki-link prefix.  prefix must be a MediaWiki-recognized language&lt;br /&gt;
code and must begin with a colon.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function link_title_ok (link, lorig, title, torig)&lt;br /&gt;
local orig;&lt;br /&gt;
	if utilities.is_set (link) then 											-- don't bother if &amp;lt;param&amp;gt;-link doesn't have a value&lt;br /&gt;
		if not link_param_ok (link) then										-- check |&amp;lt;param&amp;gt;-link= markup&lt;br /&gt;
			orig = lorig;														-- identify the failing link parameter&lt;br /&gt;
		elseif title:find ('%[%[') then											-- check |title= for wikilink markup&lt;br /&gt;
			orig = torig;														-- identify the failing |title= parameter&lt;br /&gt;
		elseif link:match ('^%a+:') then										-- if the link is what looks like an interwiki&lt;br /&gt;
			local prefix = link:match ('^(%a+):'):lower();						-- get the interwiki prefix&lt;br /&gt;
&lt;br /&gt;
			if cfg.inter_wiki_map[prefix] then									-- if prefix is in the map, must have preceding colon&lt;br /&gt;
				orig = lorig;													-- flag as error&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if utilities.is_set (orig) then&lt;br /&gt;
		link = '';																-- unset&lt;br /&gt;
		table.insert( z.message_tail, { utilities.set_message ( 'err_bad_paramlink', orig)});	-- URL or wikilink in |title= with |title-link=;&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	return link;																-- link if ok, empty string else&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; C H E C K _ U R L &amp;gt;------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Determines whether a URL string appears to be valid.&lt;br /&gt;
&lt;br /&gt;
First we test for space characters.  If any are found, return false.  Then split the URL into scheme and domain&lt;br /&gt;
portions, or for protocol-relative (//example.com) URLs, just the domain.  Use is_url() to validate the two&lt;br /&gt;
portions of the URL.  If both are valid, or for protocol-relative if domain is valid, return true, else false.&lt;br /&gt;
&lt;br /&gt;
Because it is different from a standard URL, and because this module used external_link() to make external links&lt;br /&gt;
that work for standard and news: links, we validate newsgroup names here.  The specification for a newsgroup name&lt;br /&gt;
is at https://tools.ietf.org/html/rfc5536#section-3.1.4&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function check_url( url_str )&lt;br /&gt;
	if nil == url_str:match (&amp;quot;^%S+$&amp;quot;) then										-- if there are any spaces in |url=value it can't be a proper URL&lt;br /&gt;
		return false;&lt;br /&gt;
	end&lt;br /&gt;
	local scheme, domain;&lt;br /&gt;
&lt;br /&gt;
	scheme, domain = split_url (url_str);										-- get scheme or nil and domain or nil from URL;&lt;br /&gt;
	&lt;br /&gt;
	if 'news:' == scheme then													-- special case for newsgroups&lt;br /&gt;
		return domain:match('^[%a%d%+%-_]+%.[%a%d%+%-_%.]*[%a%d%+%-_]$');&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	return is_url (scheme, domain);												-- return true if value appears to be a valid URL&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[=[-------------------------&amp;lt; I S _ P A R A M E T E R _ E X T _ W I K I L I N K &amp;gt;----------------------------&lt;br /&gt;
&lt;br /&gt;
Return true if a parameter value has a string that begins and ends with square brackets [ and ] and the first&lt;br /&gt;
non-space characters following the opening bracket appear to be a URL.  The test will also find external wikilinks&lt;br /&gt;
that use protocol-relative URLs. Also finds bare URLs.&lt;br /&gt;
&lt;br /&gt;
The frontier pattern prevents a match on interwiki-links which are similar to scheme:path URLs.  The tests that&lt;br /&gt;
find bracketed URLs are required because the parameters that call this test (currently |title=, |chapter=, |work=,&lt;br /&gt;
and |publisher=) may have wikilinks and there are articles or redirects like '//Hus' so, while uncommon, |title=[[//Hus]]&lt;br /&gt;
is possible as might be [[en://Hus]].&lt;br /&gt;
&lt;br /&gt;
]=]&lt;br /&gt;
&lt;br /&gt;
local function is_parameter_ext_wikilink (value)&lt;br /&gt;
local scheme, domain;&lt;br /&gt;
&lt;br /&gt;
	if value:match ('%f[%[]%[%a%S*:%S+.*%]') then								-- if ext. wikilink with scheme and domain: [xxxx://yyyyy.zzz]&lt;br /&gt;
		scheme, domain = split_url (value:match ('%f[%[]%[(%a%S*:%S+).*%]'));&lt;br /&gt;
	elseif value:match ('%f[%[]%[//%S+.*%]') then								-- if protocol-relative ext. wikilink: [//yyyyy.zzz]&lt;br /&gt;
		scheme, domain = split_url (value:match ('%f[%[]%[(//%S+).*%]'));&lt;br /&gt;
	elseif value:match ('%a%S*:%S+') then										-- if bare URL with scheme; may have leading or trailing plain text&lt;br /&gt;
		scheme, domain = split_url (value:match ('(%a%S*:%S+)'));&lt;br /&gt;
	elseif value:match ('//%S+') then											-- if protocol-relative bare URL: //yyyyy.zzz; may have leading or trailing plain text&lt;br /&gt;
		scheme, domain = split_url (value:match ('(//%S+)'));					-- what is left should be the domain&lt;br /&gt;
	else&lt;br /&gt;
		return false;															-- didn't find anything that is obviously a URL&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	return is_url (scheme, domain);												-- return true if value appears to be a valid URL&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[-------------------------&amp;lt; C H E C K _ F O R _ U R L &amp;gt;-----------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
loop through a list of parameters and their values.  Look at the value and if it has an external link, emit an error message.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function check_for_url (parameter_list)&lt;br /&gt;
local error_message = '';&lt;br /&gt;
	for k, v in pairs (parameter_list) do										-- for each parameter in the list&lt;br /&gt;
		if is_parameter_ext_wikilink (v) then									-- look at the value; if there is a URL add an error message&lt;br /&gt;
			if utilities.is_set(error_message) then								-- once we've added the first portion of the error message ...&lt;br /&gt;
				error_message = error_message .. &amp;quot;, &amp;quot;;							-- ... add a comma space separator&lt;br /&gt;
			end&lt;br /&gt;
			error_message = error_message .. &amp;quot;&amp;amp;#124;&amp;quot; .. k .. &amp;quot;=&amp;quot;;				-- add the failed parameter&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	if utilities.is_set (error_message) then									-- done looping, if there is an error message, display it&lt;br /&gt;
		table.insert( z.message_tail, { utilities.set_message ( 'err_param_has_ext_link', {error_message}, true ) } );&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; S A F E _ F O R _ U R L &amp;gt;------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Escape sequences for content that will be used for URL descriptions&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function safe_for_url( str )&lt;br /&gt;
	if str:match( &amp;quot;%[%[.-%]%]&amp;quot; ) ~= nil then &lt;br /&gt;
		table.insert( z.message_tail, { utilities.set_message ( 'err_wikilink_in_url', {}, true ) } );&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	return str:gsub( '[%[%]\n]', {	&lt;br /&gt;
		['['] = '&amp;amp;#91;',&lt;br /&gt;
		[']'] = '&amp;amp;#93;',&lt;br /&gt;
		['\n'] = ' ' } );&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; E X T E R N A L _ L I N K &amp;gt;----------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Format an external link with error checking&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function external_link( URL, label, source, access)&lt;br /&gt;
	local error_str = &amp;quot;&amp;quot;;&lt;br /&gt;
	local domain;&lt;br /&gt;
	local path;&lt;br /&gt;
	local base_url;&lt;br /&gt;
&lt;br /&gt;
	if not utilities.is_set ( label ) then&lt;br /&gt;
		label = URL;&lt;br /&gt;
		if utilities.is_set ( source ) then&lt;br /&gt;
			error_str = utilities.set_message ( 'err_bare_url_missing_title', { utilities.wrap_style ('parameter', source) }, false, &amp;quot; &amp;quot; );&lt;br /&gt;
		else&lt;br /&gt;
			error( cfg.messages[&amp;quot;bare_url_no_origin&amp;quot;] );&lt;br /&gt;
		end			&lt;br /&gt;
	end&lt;br /&gt;
	if not check_url( URL ) then&lt;br /&gt;
		error_str = utilities.set_message ( 'err_bad_url', {utilities.wrap_style ('parameter', source)}, false, &amp;quot; &amp;quot; ) .. error_str;&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	domain, path = URL:match ('^([/%.%-%+:%a%d]+)([/%?#].*)$');					-- split the URL into scheme plus domain and path&lt;br /&gt;
	if path then																-- if there is a path portion&lt;br /&gt;
		path = path:gsub ('[%[%]]', {['['] = '%5b', [']'] = '%5d'});					-- replace '[' and ']' with their percent-encoded values&lt;br /&gt;
		URL = table.concat ({domain, path});									-- and reassemble&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	base_url = table.concat({ &amp;quot;[&amp;quot;, URL, &amp;quot; &amp;quot;, safe_for_url (label), &amp;quot;]&amp;quot; });		-- assemble a wiki-markup URL&lt;br /&gt;
&lt;br /&gt;
	if utilities.is_set (access) then											-- access level (subscription, registration, limited)&lt;br /&gt;
		base_url = utilities.substitute (cfg.presentation['ext-link-access-signal'], {cfg.presentation[access].class, cfg.presentation[access].title, base_url});	-- add the appropriate icon&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	return table.concat ({base_url, error_str});&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; D E P R E C A T E D _ P A R A M E T E R &amp;gt;--------------------------------------&lt;br /&gt;
&lt;br /&gt;
Categorize and emit an error message when the citation contains one or more deprecated parameters.  The function includes the&lt;br /&gt;
offending parameter name to the error message.  Only one error message is emitted regardless of the number of deprecated&lt;br /&gt;
parameters in the citation.&lt;br /&gt;
&lt;br /&gt;
added_deprecated_cat is a Boolean declared in page scope variables above&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function deprecated_parameter(name)&lt;br /&gt;
	if not added_deprecated_cat then&lt;br /&gt;
		added_deprecated_cat = true;											-- note that we've added this category&lt;br /&gt;
		table.insert( z.message_tail, { utilities.set_message ( 'err_deprecated_params', {name}, true ) } );	-- add error message&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[=[-------------------------&amp;lt; K E R N _ Q U O T E S &amp;gt;--------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Apply kerning to open the space between the quote mark provided by the module and a leading or trailing quote&lt;br /&gt;
mark contained in a |title= or |chapter= parameter's value.&lt;br /&gt;
&lt;br /&gt;
This function will positive kern either single or double quotes:&lt;br /&gt;
	&amp;quot;'Unkerned title with leading and trailing single quote marks'&amp;quot;&lt;br /&gt;
	&amp;quot; 'Kerned title with leading and trailing single quote marks' &amp;quot; (in real life the kerning isn't as wide as this example)&lt;br /&gt;
Double single quotes (italic or bold wiki-markup) are not kerned.&lt;br /&gt;
&lt;br /&gt;
Replaces Unicode quote marks in plain text or in the label portion of a [[L|D]] style wikilink with typewriter&lt;br /&gt;
quote marks regardless of the need for kerning.  Unicode quote marks are not replaced in simple [[D]] wikilinks.&lt;br /&gt;
&lt;br /&gt;
Call this function for chapter titles, for website titles, etc.; not for book titles.&lt;br /&gt;
&lt;br /&gt;
]=]&lt;br /&gt;
&lt;br /&gt;
local function kern_quotes (str)&lt;br /&gt;
	local cap = '';&lt;br /&gt;
	local cap2 = '';&lt;br /&gt;
	local wl_type, label, link;&lt;br /&gt;
&lt;br /&gt;
	wl_type, label, link = utilities.is_wikilink (str);							-- wl_type is: 0, no wl (text in label variable); 1, [[D]]; 2, [[L|D]]&lt;br /&gt;
	&lt;br /&gt;
	if 1 == wl_type then														-- [[D]] simple wikilink with or without quote marks&lt;br /&gt;
		if mw.ustring.match (str, '%[%[[\&amp;quot;“”\'‘’].+[\&amp;quot;“”\'‘’]%]%]') then		-- leading and trailing quote marks&lt;br /&gt;
			str = utilities.substitute (cfg.presentation['kern-wl-both'], str);&lt;br /&gt;
		elseif mw.ustring.match (str, '%[%[[\&amp;quot;“”\'‘’].+%]%]')	then			-- leading quote marks&lt;br /&gt;
			str = utilities.substitute (cfg.presentation['kern-wl-left'], str);&lt;br /&gt;
		elseif mw.ustring.match (str, '%[%[.+[\&amp;quot;“”\'‘’]%]%]') then				-- trailing quote marks&lt;br /&gt;
			str = utilities.substitute (cfg.presentation['kern-wl-right'], str);&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
	else																		-- plain text or [[L|D]]; text in label variable&lt;br /&gt;
		label = mw.ustring.gsub (label, '[“”]', '\&amp;quot;');							-- replace “” (U+201C &amp;amp; U+201D) with &amp;quot; (typewriter double quote mark)&lt;br /&gt;
		label = mw.ustring.gsub (label, '[‘’]', '\'');							-- replace ‘’ (U+2018 &amp;amp; U+2019) with ' (typewriter single quote mark)&lt;br /&gt;
&lt;br /&gt;
		cap, cap2 = mw.ustring.match (label, &amp;quot;^([\&amp;quot;\'])([^\'].+)&amp;quot;);				-- match leading double or single quote but not doubled single quotes (italic markup)&lt;br /&gt;
		if utilities.is_set (cap) then&lt;br /&gt;
			label = utilities.substitute (cfg.presentation['kern-left'], {cap, cap2});&lt;br /&gt;
		end&lt;br /&gt;
	&lt;br /&gt;
		cap, cap2 = mw.ustring.match (label, &amp;quot;^(.+[^\'])([\&amp;quot;\'])$&amp;quot;)				-- match trailing double or single quote but not doubled single quotes (italic markup)&lt;br /&gt;
		if utilities.is_set (cap) then&lt;br /&gt;
			label = utilities.substitute (cfg.presentation['kern-right'], {cap, cap2});&lt;br /&gt;
		end&lt;br /&gt;
		&lt;br /&gt;
		if 2 == wl_type then&lt;br /&gt;
			str = utilities.make_wikilink (link, label);						-- reassemble the wikilink&lt;br /&gt;
		else&lt;br /&gt;
			str = label;&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	return str;&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; F O R M A T _ S C R I P T _ V A L U E &amp;gt;----------------------------------------&lt;br /&gt;
&lt;br /&gt;
|script-title= holds title parameters that are not written in Latin-based scripts: Chinese, Japanese, Arabic, Hebrew, etc. These scripts should&lt;br /&gt;
not be italicized and may be written right-to-left.  The value supplied by |script-title= is concatenated onto Title after Title has been wrapped&lt;br /&gt;
in italic markup.&lt;br /&gt;
&lt;br /&gt;
Regardless of language, all values provided by |script-title= are wrapped in &amp;lt;bdi&amp;gt;...&amp;lt;/bdi&amp;gt; tags to isolate RTL languages from the English left to right.&lt;br /&gt;
&lt;br /&gt;
|script-title= provides a unique feature.  The value in |script-title= may be prefixed with a two-character ISO 639-1 language code and a colon:&lt;br /&gt;
	|script-title=ja:*** *** (where * represents a Japanese character)&lt;br /&gt;
Spaces between the two-character code and the colon and the colon and the first script character are allowed:&lt;br /&gt;
	|script-title=ja : *** ***&lt;br /&gt;
	|script-title=ja: *** ***&lt;br /&gt;
	|script-title=ja :*** ***&lt;br /&gt;
Spaces preceding the prefix are allowed: |script-title = ja:*** ***&lt;br /&gt;
&lt;br /&gt;
The prefix is checked for validity.  If it is a valid ISO 639-1 language code, the lang attribute (lang=&amp;quot;ja&amp;quot;) is added to the &amp;lt;bdi&amp;gt; tag so that browsers can&lt;br /&gt;
know the language the tag contains.  This may help the browser render the script more correctly.  If the prefix is invalid, the lang attribute&lt;br /&gt;
is not added.  At this time there is no error message for this condition.&lt;br /&gt;
&lt;br /&gt;
Supports |script-title=, |script-chapter=, |script-&amp;lt;periodical&amp;gt;=&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function format_script_value (script_value, script_param)&lt;br /&gt;
	local lang='';																-- initialize to empty string&lt;br /&gt;
	local name;&lt;br /&gt;
	if script_value:match('^%l%l%l?%s*:') then									-- if first 3 or 4 non-space characters are script language prefix&lt;br /&gt;
		lang = script_value:match('^(%l%l%l?)%s*:%s*%S.*');						-- get the language prefix or nil if there is no script&lt;br /&gt;
		if not utilities.is_set (lang) then&lt;br /&gt;
			table.insert( z.message_tail, { utilities.set_message ( 'err_script_parameter', {script_param, 'missing title part'}, true ) } );		-- prefix without 'title'; add error message&lt;br /&gt;
			return '';															-- script_value was just the prefix so return empty string&lt;br /&gt;
		end&lt;br /&gt;
																				-- if we get this far we have prefix and script&lt;br /&gt;
		name = cfg.lang_code_remap[lang] or mw.language.fetchLanguageName( lang, cfg.this_wiki_code );	-- get language name so that we can use it to categorize&lt;br /&gt;
		if utilities.is_set (name) then													-- is prefix a proper ISO 639-1 language code?&lt;br /&gt;
			script_value = script_value:gsub ('^%l+%s*:%s*', '');				-- strip prefix from script&lt;br /&gt;
																				-- is prefix one of these language codes?&lt;br /&gt;
			if utilities.in_array (lang, cfg.script_lang_codes) then&lt;br /&gt;
				utilities.add_prop_cat ('script_with_name', {name, lang})&lt;br /&gt;
			else&lt;br /&gt;
				table.insert( z.message_tail, { utilities.set_message ( 'err_script_parameter', {script_param, 'unknown language code'}, true ) } );	-- unknown script-language; add error message&lt;br /&gt;
			end&lt;br /&gt;
			lang = ' lang=&amp;quot;' .. lang .. '&amp;quot; ';									-- convert prefix into a lang attribute&lt;br /&gt;
		else&lt;br /&gt;
			table.insert( z.message_tail, { utilities.set_message ( 'err_script_parameter', {script_param, 'invalid language code'}, true ) } );		-- invalid language code; add error message&lt;br /&gt;
			lang = '';															-- invalid so set lang to empty string&lt;br /&gt;
		end&lt;br /&gt;
	else&lt;br /&gt;
		table.insert( z.message_tail, { utilities.set_message ( 'err_script_parameter', {script_param, 'missing prefix'}, true ) } );				-- no language code prefix; add error message&lt;br /&gt;
	end&lt;br /&gt;
	script_value = utilities.substitute (cfg.presentation['bdi'], {lang, script_value});	-- isolate in case script is RTL&lt;br /&gt;
&lt;br /&gt;
	return script_value;&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; S C R I P T _ C O N C A T E N A T E &amp;gt;------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Initially for |title= and |script-title=, this function concatenates those two parameter values after the script value has been &lt;br /&gt;
wrapped in &amp;lt;bdi&amp;gt; tags.&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function script_concatenate (title, script, script_param)&lt;br /&gt;
	if utilities.is_set (script) then&lt;br /&gt;
		script = format_script_value (script, script_param);					-- &amp;lt;bdi&amp;gt; tags, lang attribute, categorization, etc.; returns empty string on error&lt;br /&gt;
		if utilities.is_set (script) then&lt;br /&gt;
			title = title .. ' ' .. script;										-- concatenate title and script title&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	return title;&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; W R A P _ M S G &amp;gt;--------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Applies additional message text to various parameter values. Supplied string is wrapped using a message_list&lt;br /&gt;
configuration taking one argument.  Supports lower case text for {{citation}} templates.  Additional text taken&lt;br /&gt;
from citation_config.messages - the reason this function is similar to but separate from wrap_style().&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function wrap_msg (key, str, lower)&lt;br /&gt;
	if not utilities.is_set ( str ) then&lt;br /&gt;
		return &amp;quot;&amp;quot;;&lt;br /&gt;
	end&lt;br /&gt;
	if true == lower then&lt;br /&gt;
		local msg;&lt;br /&gt;
		msg = cfg.messages[key]:lower();										-- set the message to lower case before &lt;br /&gt;
		return utilities.substitute ( msg, str );								-- including template text&lt;br /&gt;
	else&lt;br /&gt;
		return utilities.substitute ( cfg.messages[key], str );&lt;br /&gt;
	end		&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; W I K I S O U R C E _ U R L _ M A K E &amp;gt;----------------------------------------&lt;br /&gt;
&lt;br /&gt;
Makes a Wikisource URL from Wikisource interwiki-link.  Returns the URL and appropriate label; nil else.&lt;br /&gt;
&lt;br /&gt;
str is the value assigned to |chapter= (or aliases) or |title= or |title-link=&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function wikisource_url_make (str)&lt;br /&gt;
	local wl_type, D, L;&lt;br /&gt;
	local ws_url, ws_label;&lt;br /&gt;
	local wikisource_prefix = table.concat ({'https://', cfg.this_wiki_code, '.wikisource.org/wiki/'});&lt;br /&gt;
&lt;br /&gt;
	wl_type, D, L = utilities.is_wikilink (str);								-- wl_type is 0 (not a wikilink), 1 (simple wikilink), 2 (complex wikilink)&lt;br /&gt;
&lt;br /&gt;
	if 0 == wl_type then														-- not a wikilink; might be from |title-link=&lt;br /&gt;
		str = D:match ('^[Ww]ikisource:(.+)') or D:match ('^[Ss]:(.+)');		-- article title from interwiki link with long-form or short-form namespace&lt;br /&gt;
		if utilities.is_set (str) then&lt;br /&gt;
			ws_url = table.concat ({											-- build a Wikisource URL&lt;br /&gt;
				wikisource_prefix,												-- prefix&lt;br /&gt;
				str,															-- article title&lt;br /&gt;
				});&lt;br /&gt;
			ws_label = str;														-- label for the URL&lt;br /&gt;
		end&lt;br /&gt;
	elseif 1 == wl_type then													-- simple wikilink: [[Wikisource:ws article]]&lt;br /&gt;
		str = D:match ('^[Ww]ikisource:(.+)') or D:match ('^[Ss]:(.+)');		-- article title from interwiki link with long-form or short-form namespace&lt;br /&gt;
		if utilities.is_set (str) then&lt;br /&gt;
			ws_url = table.concat ({											-- build a Wikisource URL&lt;br /&gt;
				wikisource_prefix,												-- prefix&lt;br /&gt;
				str,															-- article title&lt;br /&gt;
				});&lt;br /&gt;
			ws_label = str;														-- label for the URL&lt;br /&gt;
		end&lt;br /&gt;
	elseif 2 == wl_type then													-- non-so-simple wikilink: [[Wikisource:ws article|displayed text]] ([[L|D]])&lt;br /&gt;
		str = L:match ('^[Ww]ikisource:(.+)') or L:match ('^[Ss]:(.+)');		-- article title from interwiki link with long-form or short-form namespace&lt;br /&gt;
		if utilities.is_set (str) then&lt;br /&gt;
			ws_label = D;														-- get ws article name from display portion of interwiki link&lt;br /&gt;
			ws_url = table.concat ({											-- build a Wikisource URL&lt;br /&gt;
				wikisource_prefix,												-- prefix&lt;br /&gt;
				str,															-- article title without namespace from link portion of wikilink&lt;br /&gt;
				});&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	if ws_url then&lt;br /&gt;
		ws_url = mw.uri.encode (ws_url, 'WIKI');								-- make a usable URL&lt;br /&gt;
		ws_url = ws_url:gsub ('%%23', '#');										-- undo percent encoding of fragment marker&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	return ws_url, ws_label, L or D;											-- return proper URL or nil and a label or nil&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; F O R M A T _ P E R I O D I C A L &amp;gt;--------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Format the three periodical parameters: |script-&amp;lt;periodical&amp;gt;=, |&amp;lt;periodical&amp;gt;=, and |trans-&amp;lt;periodical&amp;gt;= into a single Periodical meta-&lt;br /&gt;
parameter.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function format_periodical (script_periodical, script_periodical_source, periodical, trans_periodical)&lt;br /&gt;
	local periodical_error = '';&lt;br /&gt;
&lt;br /&gt;
	if not utilities.is_set (periodical) then&lt;br /&gt;
		periodical = '';														-- to be safe for concatenation&lt;br /&gt;
	else&lt;br /&gt;
		periodical = utilities.wrap_style ('italic-title', periodical);			-- style &lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	periodical = script_concatenate (periodical, script_periodical, script_periodical_source);	-- &amp;lt;bdi&amp;gt; tags, lang attribute, categorization, etc.; must be done after title is wrapped&lt;br /&gt;
&lt;br /&gt;
	if utilities.is_set (trans_periodical) then&lt;br /&gt;
		trans_periodical = utilities.wrap_style ('trans-italic-title', trans_periodical);&lt;br /&gt;
		if utilities.is_set (periodical) then&lt;br /&gt;
			periodical = periodical .. ' ' .. trans_periodical;&lt;br /&gt;
		else																	-- here when trans-periodical without periodical or script-periodical&lt;br /&gt;
			periodical = trans_periodical;&lt;br /&gt;
			periodical_error = ' ' .. utilities.set_message ('err_trans_missing_title', {'periodical'});&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	return periodical .. periodical_error;&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; F O R M A T _ C H A P T E R _ T I T L E &amp;gt;--------------------------------------&lt;br /&gt;
&lt;br /&gt;
Format the four chapter parameters: |script-chapter=, |chapter=, |trans-chapter=, and |chapter-url= into a single chapter meta-&lt;br /&gt;
parameter (chapter_url_source used for error messages).&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function format_chapter_title (script_chapter, script_chapter_source, chapter, chapter_source, trans_chapter, trans_chapter_source, chapter_url, chapter_url_source, no_quotes, access)&lt;br /&gt;
	local chapter_error = '';&lt;br /&gt;
&lt;br /&gt;
	local ws_url, ws_label, L = wikisource_url_make (chapter);					-- make a wikisource URL and label from a wikisource interwiki link&lt;br /&gt;
	if ws_url then&lt;br /&gt;
		ws_label = ws_label:gsub ('_', '');										-- replace underscore separaters with space characters&lt;br /&gt;
		chapter = ws_label;&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if not utilities.is_set (chapter) then&lt;br /&gt;
		chapter = '';															-- to be safe for concatenation&lt;br /&gt;
	else&lt;br /&gt;
		if false == no_quotes then&lt;br /&gt;
			chapter = kern_quotes (chapter);									-- if necessary, separate chapter title's leading and trailing quote marks from module provided quote marks&lt;br /&gt;
			chapter = utilities.wrap_style ('quoted-title', chapter);&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	chapter = script_concatenate (chapter, script_chapter, script_chapter_source);	-- &amp;lt;bdi&amp;gt; tags, lang attribute, categorization, etc.; must be done after title is wrapped&lt;br /&gt;
&lt;br /&gt;
	if utilities.is_set (chapter_url) then&lt;br /&gt;
		chapter = external_link (chapter_url, chapter, chapter_url_source, access);	-- adds bare_url_missing_title error if appropriate&lt;br /&gt;
	elseif ws_url then&lt;br /&gt;
		chapter = external_link (ws_url, chapter .. '&amp;amp;nbsp;', 'ws link in chapter');	-- adds bare_url_missing_title error if appropriate; space char to move icon away from chap text; TODO: better way to do this?&lt;br /&gt;
		chapter = utilities.substitute (cfg.presentation['interwiki-icon'], {cfg.presentation['class-wikisource'], L, chapter});				&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if utilities.is_set (trans_chapter) then&lt;br /&gt;
		trans_chapter = utilities.wrap_style ('trans-quoted-title', trans_chapter);&lt;br /&gt;
		if utilities.is_set (chapter) then&lt;br /&gt;
			chapter = chapter .. ' ' .. trans_chapter;&lt;br /&gt;
		else																	-- here when trans_chapter without chapter or script-chapter&lt;br /&gt;
			chapter = trans_chapter;&lt;br /&gt;
			chapter_source = trans_chapter_source:match ('trans%-?(.+)');		-- when no chapter, get matching name from trans-&amp;lt;param&amp;gt;&lt;br /&gt;
			chapter_error = ' ' .. utilities.set_message ('err_trans_missing_title', {chapter_source});&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	return chapter .. chapter_error;&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; H A S _ I N V I S I B L E _ C H A R S &amp;gt;----------------------------------------&lt;br /&gt;
&lt;br /&gt;
This function searches a parameter's value for non-printable or invisible characters.  The search stops at the&lt;br /&gt;
first match.&lt;br /&gt;
&lt;br /&gt;
This function will detect the visible replacement character when it is part of the Wikisource.&lt;br /&gt;
&lt;br /&gt;
Detects but ignores nowiki and math stripmarkers.  Also detects other named stripmarkers (gallery, math, pre, ref)&lt;br /&gt;
and identifies them with a slightly different error message.  See also coins_cleanup().&lt;br /&gt;
&lt;br /&gt;
Output of this function is an error message that identifies the character or the Unicode group, or the stripmarker&lt;br /&gt;
that was detected along with its position (or, for multi-byte characters, the position of its first byte) in the&lt;br /&gt;
parameter value.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function has_invisible_chars (param, v)&lt;br /&gt;
	local position = '';														-- position of invisible char or starting position of stripmarker&lt;br /&gt;
	local dummy;																-- end of matching string; not used but required to hold end position when a capture is returned&lt;br /&gt;
	local capture;																-- used by stripmarker detection to hold name of the stripmarker&lt;br /&gt;
	local i = 1;&lt;br /&gt;
	local stripmarker, apostrophe;&lt;br /&gt;
	&lt;br /&gt;
	capture = string.match (v, '[%w%p ]*');										-- test for values that are simple ASCII text and bypass other tests if true&lt;br /&gt;
	if capture == v then														-- if same there are no Unicode characters&lt;br /&gt;
		return;&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	while cfg.invisible_chars[i] do&lt;br /&gt;
		local char = cfg.invisible_chars[i][1]									-- the character or group name&lt;br /&gt;
		local pattern = cfg.invisible_chars[i][2]									-- the pattern used to find it&lt;br /&gt;
		position, dummy, capture = mw.ustring.find (v, pattern)					-- see if the parameter value contains characters that match the pattern&lt;br /&gt;
		&lt;br /&gt;
		if position and (char == 'zero width joiner') then						-- if we found a zero-width joiner character&lt;br /&gt;
			if mw.ustring.find (v, cfg.indic_script) then						-- it's ok if one of the Indic scripts&lt;br /&gt;
				position = nil;													-- unset position&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
		&lt;br /&gt;
		if position then&lt;br /&gt;
			if 'nowiki' == capture or 'math' == capture or						-- nowiki and math stripmarkers (not an error condition)&lt;br /&gt;
				('templatestyles' == capture and utilities.in_array (param, {'id', 'quote'})) then	-- templatestyles stripmarker allowed in these parameters&lt;br /&gt;
					stripmarker = true;											-- set a flag&lt;br /&gt;
			elseif true == stripmarker and 'delete' == char then				-- because stripmakers begin and end with the delete char, assume that we've found one end of a stripmarker&lt;br /&gt;
				position = nil;													-- unset&lt;br /&gt;
			else&lt;br /&gt;
				local err_msg;&lt;br /&gt;
				if capture then&lt;br /&gt;
					err_msg = capture .. ' ' .. char;&lt;br /&gt;
				else&lt;br /&gt;
					err_msg = char .. ' ' .. 'character';&lt;br /&gt;
				end&lt;br /&gt;
&lt;br /&gt;
				table.insert( z.message_tail, { utilities.set_message ( 'err_invisible_char', {err_msg, utilities.wrap_style ('parameter', param), position}, true ) } );	-- add error message&lt;br /&gt;
				return;															-- and done with this parameter&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
		i = i+1;																-- bump our index&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; A R G U M E N T _ W R A P P E R &amp;gt;----------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Argument wrapper.  This function provides support for argument mapping defined in the configuration file so that&lt;br /&gt;
multiple names can be transparently aliased to single internal variable.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function argument_wrapper ( args )&lt;br /&gt;
	local origin = {};&lt;br /&gt;
	&lt;br /&gt;
	return setmetatable({&lt;br /&gt;
		ORIGIN = function ( self, k )&lt;br /&gt;
			local dummy = self[k]; --force the variable to be loaded.&lt;br /&gt;
			return origin[k];&lt;br /&gt;
		end&lt;br /&gt;
	},&lt;br /&gt;
	{&lt;br /&gt;
		__index = function ( tbl, k )&lt;br /&gt;
			if origin[k] ~= nil then&lt;br /&gt;
				return nil;&lt;br /&gt;
			end&lt;br /&gt;
			&lt;br /&gt;
			local args, list, v = args, cfg.aliases[k];&lt;br /&gt;
			&lt;br /&gt;
			if type( list ) == 'table' then&lt;br /&gt;
				v, origin[k] = utilities.select_one ( args, list, 'err_redundant_parameters' );&lt;br /&gt;
				if origin[k] == nil then&lt;br /&gt;
					origin[k] = ''; -- Empty string, not nil&lt;br /&gt;
				end&lt;br /&gt;
			elseif list ~= nil then&lt;br /&gt;
				v, origin[k] = args[list], list;&lt;br /&gt;
			else&lt;br /&gt;
				-- maybe let through instead of raising an error?&lt;br /&gt;
				-- v, origin[k] = args[k], k;&lt;br /&gt;
				error( cfg.messages['unknown_argument_map'] .. ': ' .. k);&lt;br /&gt;
			end&lt;br /&gt;
			&lt;br /&gt;
			-- Empty strings, not nil;&lt;br /&gt;
			if v == nil then&lt;br /&gt;
				v = '';&lt;br /&gt;
				origin[k] = '';&lt;br /&gt;
			end&lt;br /&gt;
			&lt;br /&gt;
			tbl = rawset( tbl, k, v );&lt;br /&gt;
			return v;&lt;br /&gt;
		end,&lt;br /&gt;
	});&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; N O W R A P _ D A T E &amp;gt;--------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
When date is YYYY-MM-DD format wrap in nowrap span: &amp;lt;span ...&amp;gt;YYYY-MM-DD&amp;lt;/span&amp;gt;.  When date is DD MMMM YYYY or is&lt;br /&gt;
MMMM DD, YYYY then wrap in nowrap span: &amp;lt;span ...&amp;gt;DD MMMM&amp;lt;/span&amp;gt; YYYY or &amp;lt;span ...&amp;gt;MMMM DD,&amp;lt;/span&amp;gt; YYYY&lt;br /&gt;
&lt;br /&gt;
DOES NOT yet support MMMM YYYY or any of the date ranges.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function nowrap_date (date)&lt;br /&gt;
	local cap = '';&lt;br /&gt;
	local cap2 = '';&lt;br /&gt;
&lt;br /&gt;
	if date:match(&amp;quot;^%d%d%d%d%-%d%d%-%d%d$&amp;quot;) then&lt;br /&gt;
		date = utilities.substitute (cfg.presentation['nowrap1'], date);&lt;br /&gt;
	&lt;br /&gt;
	elseif date:match(&amp;quot;^%a+%s*%d%d?,%s+%d%d%d%d$&amp;quot;) or date:match (&amp;quot;^%d%d?%s*%a+%s+%d%d%d%d$&amp;quot;) then&lt;br /&gt;
		cap, cap2 = string.match (date, &amp;quot;^(.*)%s+(%d%d%d%d)$&amp;quot;);&lt;br /&gt;
		date = utilities.substitute (cfg.presentation['nowrap2'], {cap, cap2});&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	return date;&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; S E T _ T I T L E T Y P E &amp;gt;----------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
This function sets default title types (equivalent to the citation including |type=&amp;lt;default value&amp;gt;) for those templates that have defaults.&lt;br /&gt;
Also handles the special case where it is desirable to omit the title type from the rendered citation (|type=none).&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function set_titletype (cite_class, title_type)&lt;br /&gt;
	if utilities.is_set (title_type) then&lt;br /&gt;
		if 'none' == cfg.keywords_xlate[title_type] then&lt;br /&gt;
			title_type = '';													-- if |type=none then type parameter not displayed&lt;br /&gt;
		end&lt;br /&gt;
		return title_type;														-- if |type= has been set to any other value use that value&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	return cfg.title_types [cite_class] or '';									-- set template's default title type; else empty string for concatenation&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; H Y P H E N _ T O _ D A S H &amp;gt;--------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Converts a hyphen to a dash under certain conditions.  The hyphen must separate like items; unlike items are&lt;br /&gt;
returned unmodified.  These forms are modified:&lt;br /&gt;
	letter - letter (A - B)&lt;br /&gt;
	digit - digit (4-5)&lt;br /&gt;
	digit separator digit - digit separator digit (4.1-4.5 or 4-1-4-5)&lt;br /&gt;
	letterdigit - letterdigit (A1-A5) (an optional separator between letter and digit is supported – a.1-a.5 or a-1-a-5)&lt;br /&gt;
	digitletter - digitletter (5a - 5d) (an optional separator between letter and digit is supported – 5.a-5.d or 5-a-5-d)&lt;br /&gt;
&lt;br /&gt;
any other forms are returned unmodified.&lt;br /&gt;
&lt;br /&gt;
str may be a comma- or semicolon-separated list&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function hyphen_to_dash( str )&lt;br /&gt;
	if not utilities.is_set (str) then&lt;br /&gt;
		return str;&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local accept;																-- Boolean&lt;br /&gt;
	str, accept = utilities.has_accept_as_written (str);						-- remove accept-this-as-written markup when it wraps all of str&lt;br /&gt;
	if accept then&lt;br /&gt;
		return str;																-- when markup removed, nothing to do, we're done&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	str = str:gsub ('&amp;amp;[nm]dash;', {['&amp;amp;ndash;'] = '–', ['&amp;amp;mdash;'] = '—'});		-- replace &amp;amp;mdash; and &amp;amp;ndash; entities with their characters; semicolon mucks up the text.split&lt;br /&gt;
	str = str:gsub ('&amp;amp;#45;', '-');												-- replace HTML numeric entity with hyphen character&lt;br /&gt;
	str = str:gsub ('&amp;amp;nbsp;', ' ');												-- replace &amp;amp;nbsp; entity with generic keyboard space character&lt;br /&gt;
	&lt;br /&gt;
	local out = {};&lt;br /&gt;
	local list = mw.text.split (str, '%s*[,;]%s*');								-- split str at comma or semicolon separators if there are any&lt;br /&gt;
&lt;br /&gt;
	for _, item in ipairs (list) do												-- for each item in the list&lt;br /&gt;
		if mw.ustring.match (item, '^%w*[%.%-]?%w+%s*[%-–—]%s*%w*[%.%-]?%w+$') then	-- if a hyphenated range or has endash or emdash separators&lt;br /&gt;
			if item:match ('^%a+[%.%-]?%d+%s*%-%s*%a+[%.%-]?%d+$') or			-- letterdigit hyphen letterdigit (optional separator between letter and digit)&lt;br /&gt;
				item:match ('^%d+[%.%-]?%a+%s*%-%s*%d+[%.%-]?%a+$') or			-- digitletter hyphen digitletter (optional separator between digit and letter)&lt;br /&gt;
				item:match ('^%d+[%.%-]%d+%s*%-%s*%d+[%.%-]%d+$') or			-- digit separator digit hyphen digit separator digit&lt;br /&gt;
				item:match ('^%d+%s*%-%s*%d+$') or								-- digit hyphen digit&lt;br /&gt;
				item:match ('^%a+%s*%-%s*%a+$') then							-- letter hyphen letter&lt;br /&gt;
					item = item:gsub ('(%w*[%.%-]?%w+)%s*%-%s*(%w*[%.%-]?%w+)', '%1–%2');	-- replace hyphen, remove extraneous space characters&lt;br /&gt;
			else&lt;br /&gt;
				item = mw.ustring.gsub (item, '%s*[–—]%s*', '–');				-- for endash or emdash separated ranges, replace em with en, remove extraneous whitespace&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
		item = utilities.has_accept_as_written (item);							-- remove accept-this-as-written markup when it wraps all of str&lt;br /&gt;
		table.insert (out, item);												-- add the (possibly modified) item to the output table&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	return table.concat (out, ', ');											-- concatenate the output table into a comma separated string&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; S A F E _ J O I N &amp;gt;------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Joins a sequence of strings together while checking for duplicate separation characters.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function safe_join( tbl, duplicate_char )&lt;br /&gt;
	local f = {};																-- create a function table appropriate to type of 'duplicate character'&lt;br /&gt;
		if 1 == #duplicate_char then											-- for single byte ASCII characters use the string library functions&lt;br /&gt;
			f.gsub = string.gsub&lt;br /&gt;
			f.match = string.match&lt;br /&gt;
			f.sub = string.sub&lt;br /&gt;
		else																	-- for multi-byte characters use the ustring library functions&lt;br /&gt;
			f.gsub = mw.ustring.gsub&lt;br /&gt;
			f.match = mw.ustring.match&lt;br /&gt;
			f.sub = mw.ustring.sub&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
	local str = '';																-- the output string&lt;br /&gt;
	local comp = '';															-- what does 'comp' mean?&lt;br /&gt;
	local end_chr = '';&lt;br /&gt;
	local trim;&lt;br /&gt;
	for _, value in ipairs( tbl ) do&lt;br /&gt;
		if value == nil then value = ''; end&lt;br /&gt;
		&lt;br /&gt;
		if str == '' then														-- if output string is empty&lt;br /&gt;
			str = value;														-- assign value to it (first time through the loop)&lt;br /&gt;
		elseif value ~= '' then&lt;br /&gt;
			if value:sub(1, 1) == '&amp;lt;' then										-- special case of values enclosed in spans and other markup.&lt;br /&gt;
				comp = value:gsub( &amp;quot;%b&amp;lt;&amp;gt;&amp;quot;, &amp;quot;&amp;quot; );								-- remove HTML markup (&amp;lt;span&amp;gt;string&amp;lt;/span&amp;gt; -&amp;gt; string)&lt;br /&gt;
			else&lt;br /&gt;
				comp = value;&lt;br /&gt;
			end&lt;br /&gt;
																				-- typically duplicate_char is sepc&lt;br /&gt;
			if f.sub(comp, 1, 1) == duplicate_char then							-- is first character same as duplicate_char? why test first character?&lt;br /&gt;
																				--   Because individual string segments often (always?) begin with terminal punct for the&lt;br /&gt;
																				--   preceding segment: 'First element' .. 'sepc next element' .. etc.?&lt;br /&gt;
				trim = false;&lt;br /&gt;
				end_chr = f.sub(str, -1, -1);									-- get the last character of the output string&lt;br /&gt;
				-- str = str .. &amp;quot;&amp;lt;HERE(enchr=&amp;quot; .. end_chr .. &amp;quot;)&amp;quot;					-- debug stuff?&lt;br /&gt;
				if end_chr == duplicate_char then								-- if same as separator&lt;br /&gt;
					str = f.sub(str, 1, -2);										-- remove it&lt;br /&gt;
				elseif end_chr == &amp;quot;'&amp;quot; then										-- if it might be wiki-markup&lt;br /&gt;
					if f.sub(str, -3, -1) == duplicate_char .. &amp;quot;''&amp;quot; then			-- if last three chars of str are sepc'' &lt;br /&gt;
						str = f.sub(str, 1, -4) .. &amp;quot;''&amp;quot;;						-- remove them and add back ''&lt;br /&gt;
					elseif  f.sub(str, -5, -1) == duplicate_char .. &amp;quot;]]''&amp;quot; then	-- if last five chars of str are sepc]]'' &lt;br /&gt;
						trim = true;											-- why? why do this and next differently from previous?&lt;br /&gt;
					elseif f.sub(str, -4, -1) == duplicate_char .. &amp;quot;]''&amp;quot; then	-- if last four chars of str are sepc]'' &lt;br /&gt;
						trim = true;											-- same question&lt;br /&gt;
					end&lt;br /&gt;
				elseif end_chr == &amp;quot;]&amp;quot; then										-- if it might be wiki-markup&lt;br /&gt;
					if f.sub(str, -3, -1) == duplicate_char .. &amp;quot;]]&amp;quot; then			-- if last three chars of str are sepc]] wikilink &lt;br /&gt;
						trim = true;&lt;br /&gt;
					elseif f.sub(str, -3, -1) == duplicate_char .. '&amp;quot;]' then		-- if last three chars of str are sepc&amp;quot;] quoted external link &lt;br /&gt;
						trim = true;&lt;br /&gt;
					elseif  f.sub(str, -2, -1) == duplicate_char .. &amp;quot;]&amp;quot; then		-- if last two chars of str are sepc] external link&lt;br /&gt;
						trim = true;&lt;br /&gt;
					elseif f.sub(str, -4, -1) == duplicate_char .. &amp;quot;'']&amp;quot; then	-- normal case when |url=something &amp;amp; |title=Title.&lt;br /&gt;
						trim = true;&lt;br /&gt;
					end&lt;br /&gt;
				elseif end_chr == &amp;quot; &amp;quot; then										-- if last char of output string is a space&lt;br /&gt;
					if f.sub(str, -2, -1) == duplicate_char .. &amp;quot; &amp;quot; then			-- if last two chars of str are &amp;lt;sepc&amp;gt;&amp;lt;space&amp;gt;&lt;br /&gt;
						str = f.sub(str, 1, -3);									-- remove them both&lt;br /&gt;
					end&lt;br /&gt;
				end&lt;br /&gt;
&lt;br /&gt;
				if trim then&lt;br /&gt;
					if value ~= comp then 										-- value does not equal comp when value contains HTML markup&lt;br /&gt;
						local dup2 = duplicate_char;&lt;br /&gt;
						if f.match(dup2, &amp;quot;%A&amp;quot; ) then dup2 = &amp;quot;%&amp;quot; .. dup2; end	-- if duplicate_char not a letter then escape it&lt;br /&gt;
						&lt;br /&gt;
						value = f.gsub(value, &amp;quot;(%b&amp;lt;&amp;gt;)&amp;quot; .. dup2, &amp;quot;%1&amp;quot;, 1 )		-- remove duplicate_char if it follows HTML markup&lt;br /&gt;
					else&lt;br /&gt;
						value = f.sub(value, 2, -1 );							-- remove duplicate_char when it is first character&lt;br /&gt;
					end&lt;br /&gt;
				end&lt;br /&gt;
			end&lt;br /&gt;
			str = str .. value;													--add it to the output string&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	return str;&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; I S _ S U F F I X &amp;gt;------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
returns true is suffix is properly formed Jr, Sr, or ordinal in the range 1–9.  Puncutation not allowed.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function is_suffix (suffix)&lt;br /&gt;
	if utilities.in_array (suffix, {'Jr', 'Sr', 'Jnr', 'Snr', '1st', '2nd', '3rd'}) or suffix:match ('^%dth$') then&lt;br /&gt;
		return true;&lt;br /&gt;
	end&lt;br /&gt;
	return false;&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; I S _ G O O D _ V A N C _ N A M E &amp;gt;--------------------------------------------&lt;br /&gt;
&lt;br /&gt;
For Vancouver style, author/editor names are supposed to be rendered in Latin (read ASCII) characters.  When a name&lt;br /&gt;
uses characters that contain diacritical marks, those characters are to converted to the corresponding Latin character.&lt;br /&gt;
When a name is written using a non-Latin alphabet or logogram, that name is to be transliterated into Latin characters.&lt;br /&gt;
These things are not currently possible in this module so are left to the editor to do.&lt;br /&gt;
&lt;br /&gt;
This test allows |first= and |last= names to contain any of the letters defined in the four Unicode Latin character sets&lt;br /&gt;
	[http://www.unicode.org/charts/PDF/U0000.pdf C0 Controls and Basic Latin] 0041–005A, 0061–007A&lt;br /&gt;
	[http://www.unicode.org/charts/PDF/U0080.pdf C1 Controls and Latin-1 Supplement] 00C0–00D6, 00D8–00F6, 00F8–00FF&lt;br /&gt;
	[http://www.unicode.org/charts/PDF/U0100.pdf Latin Extended-A] 0100–017F&lt;br /&gt;
	[http://www.unicode.org/charts/PDF/U0180.pdf Latin Extended-B] 0180–01BF, 01C4–024F&lt;br /&gt;
&lt;br /&gt;
|lastn= also allowed to contain hyphens, spaces, and apostrophes. (http://www.ncbi.nlm.nih.gov/books/NBK7271/box/A35029/)&lt;br /&gt;
|firstn= also allowed to contain hyphens, spaces, apostrophes, and periods&lt;br /&gt;
&lt;br /&gt;
This original test:&lt;br /&gt;
	if nil == mw.ustring.find (last, &amp;quot;^[A-Za-zÀ-ÖØ-öø-ƿǄ-ɏ%-%s%']*$&amp;quot;) or nil == mw.ustring.find (first, &amp;quot;^[A-Za-zÀ-ÖØ-öø-ƿǄ-ɏ%-%s%'%.]+[2-6%a]*$&amp;quot;) then&lt;br /&gt;
was written outside of the code editor and pasted here because the code editor gets confused between character insertion point and cursor position.&lt;br /&gt;
The test has been rewritten to use decimal character escape sequence for the individual bytes of the Unicode characters so that it is not necessary&lt;br /&gt;
to use an external editor to maintain this code.&lt;br /&gt;
&lt;br /&gt;
	\195\128-\195\150 – À-Ö (U+00C0–U+00D6 – C0 controls)&lt;br /&gt;
	\195\152-\195\182 – Ø-ö (U+00D8-U+00F6 – C0 controls)&lt;br /&gt;
	\195\184-\198\191 – ø-ƿ (U+00F8-U+01BF – C0 controls, Latin extended A &amp;amp; B)&lt;br /&gt;
	\199\132-\201\143 – Ǆ-ɏ (U+01C4-U+024F – Latin extended B)&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function is_good_vanc_name (last, first, suffix)&lt;br /&gt;
	if not suffix then&lt;br /&gt;
		if first:find ('[,%s]') then											-- when there is a space or comma, might be first name/initials + generational suffix&lt;br /&gt;
			first = first:match ('(.-)[,%s]+');									-- get name/initials&lt;br /&gt;
			suffix = first:match ('[,%s]+(.+)$');								-- get generational suffix&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	if utilities.is_set (suffix) then&lt;br /&gt;
		if not is_suffix (suffix) then&lt;br /&gt;
			add_vanc_error (cfg.err_msg_supl.suffix);&lt;br /&gt;
			return false;														-- not a name with an appropriate suffix&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	if nil == mw.ustring.find (last, &amp;quot;^[A-Za-z\195\128-\195\150\195\152-\195\182\195\184-\198\191\199\132-\201\143%-%s%']*$&amp;quot;) or&lt;br /&gt;
		nil == mw.ustring.find (first, &amp;quot;^[A-Za-z\195\128-\195\150\195\152-\195\182\195\184-\198\191\199\132-\201\143%-%s%'%.]*$&amp;quot;) then&lt;br /&gt;
			add_vanc_error (cfg.err_msg_supl['non-Latin char']);&lt;br /&gt;
			return false;														-- not a string of Latin characters; Vancouver requires Romanization&lt;br /&gt;
	end;&lt;br /&gt;
	return true;&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; R E D U C E _ T O _ I N I T I A L S &amp;gt;------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Attempts to convert names to initials in support of |name-list-style=vanc.  &lt;br /&gt;
&lt;br /&gt;
Names in |firstn= may be separated by spaces or hyphens, or for initials, a period. See http://www.ncbi.nlm.nih.gov/books/NBK7271/box/A35062/.&lt;br /&gt;
&lt;br /&gt;
Vancouver style requires family rank designations (Jr, II, III, etc.) to be rendered as Jr, 2nd, 3rd, etc.  See http://www.ncbi.nlm.nih.gov/books/NBK7271/box/A35085/.&lt;br /&gt;
This code only accepts and understands generational suffix in the Vancouver format because Roman numerals look like, and can be mistaken for, initials.&lt;br /&gt;
&lt;br /&gt;
This function uses ustring functions because firstname initials may be any of the Unicode Latin characters accepted by is_good_vanc_name ().&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function reduce_to_initials(first)&lt;br /&gt;
	local name, suffix = mw.ustring.match(first, &amp;quot;^(%u+) ([%dJS][%drndth]+)$&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
	if not name then															-- if not initials and a suffix&lt;br /&gt;
		name = mw.ustring.match(first, &amp;quot;^(%u+)$&amp;quot;);								-- is it just initials?&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if name then																-- if first is initials with or without suffix&lt;br /&gt;
		if 3 &amp;gt; mw.ustring.len (name) then										-- if one or two initials&lt;br /&gt;
			if suffix then														-- if there is a suffix&lt;br /&gt;
				if is_suffix (suffix) then										-- is it legitimate?&lt;br /&gt;
					return first;												-- one or two initials and a valid suffix so nothing to do&lt;br /&gt;
				else&lt;br /&gt;
					add_vanc_error (cfg.err_msg_supl.suffix);					-- one or two initials with invalid suffix so error message&lt;br /&gt;
					return first;												-- and return first unmolested&lt;br /&gt;
				end&lt;br /&gt;
			else&lt;br /&gt;
				return first;													-- one or two initials without suffix; nothing to do&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	end																			-- if here then name has 3 or more uppercase letters so treat them as a word&lt;br /&gt;
&lt;br /&gt;
	local initials, names = {}, {};												-- tables to hold name parts and initials&lt;br /&gt;
	local i = 1;																-- counter for number of initials&lt;br /&gt;
&lt;br /&gt;
	names = mw.text.split (first, '[%s,]+');									-- split into a table of names and possible suffix&lt;br /&gt;
&lt;br /&gt;
	while names[i] do															-- loop through the table&lt;br /&gt;
		if 1 &amp;lt; i and names[i]:match ('[%dJS][%drndth]+%.?$') then				-- if not the first name, and looks like a suffix (may have trailing dot)&lt;br /&gt;
			names[i] = names[i]:gsub ('%.', '');								-- remove terminal dot if present&lt;br /&gt;
			if is_suffix (names[i]) then										-- if a legitimate suffix&lt;br /&gt;
				table.insert (initials, ' ' .. names[i]);						-- add a separator space, insert at end of initials table&lt;br /&gt;
				break;															-- and done because suffix must fall at the end of a name&lt;br /&gt;
			end																	-- no error message if not a suffix; possibly because of Romanization&lt;br /&gt;
		end&lt;br /&gt;
		if 3 &amp;gt; i then&lt;br /&gt;
			table.insert (initials, mw.ustring.sub(names[i], 1, 1));				-- insert the initial at end of initials table&lt;br /&gt;
		end&lt;br /&gt;
		i = i+1;																-- bump the counter&lt;br /&gt;
	end&lt;br /&gt;
			&lt;br /&gt;
	return table.concat(initials)												-- Vancouver format does not include spaces.&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; L I S T _ P E O P L E &amp;gt;-------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Formats a list of people (e.g. authors, contributors, editors, interviewers, translators) &lt;br /&gt;
&lt;br /&gt;
names in the list will be linked when&lt;br /&gt;
	|&amp;lt;name&amp;gt;-link= has a value&lt;br /&gt;
	|&amp;lt;name&amp;gt;-mask- does NOT have a value; masked names are presumed to have been rendered previously so should have been linked there&lt;br /&gt;
&lt;br /&gt;
when |&amp;lt;name&amp;gt;-mask=0, the associated name is not rendered&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function list_people (control, people, etal)&lt;br /&gt;
	local sep;&lt;br /&gt;
	local namesep;&lt;br /&gt;
	local format = control.format;&lt;br /&gt;
	local maximum = control.maximum;&lt;br /&gt;
	local lastauthoramp = control.lastauthoramp;							-- TODO: delete after deprecation&lt;br /&gt;
	local name_list = {};&lt;br /&gt;
&lt;br /&gt;
	if 'vanc' == format then													-- Vancouver-like name styling?&lt;br /&gt;
		sep = cfg.presentation['sep_nl_vanc'];									-- name-list separator between names is a comma&lt;br /&gt;
		namesep = cfg.presentation['sep_name_vanc'];							-- last/first separator is a space&lt;br /&gt;
		lastauthoramp = nil;												-- TODO: delete after deprecation	-- unset because isn't used by Vancouver style&lt;br /&gt;
	else&lt;br /&gt;
		sep = cfg.presentation['sep_nl'];										-- name-list separator between names is a semicolon&lt;br /&gt;
		namesep = cfg.presentation['sep_name'];									-- last/first separator is &amp;lt;comma&amp;gt;&amp;lt;space&amp;gt;&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	if sep:sub (-1, -1) ~= &amp;quot; &amp;quot; then sep = sep .. &amp;quot; &amp;quot; end&lt;br /&gt;
	if utilities.is_set (maximum) and maximum &amp;lt; 1 then return &amp;quot;&amp;quot;, 0; end		-- returned 0 is for EditorCount; not used for other names&lt;br /&gt;
	&lt;br /&gt;
	for i, person in ipairs (people) do&lt;br /&gt;
		if utilities.is_set (person.last) then&lt;br /&gt;
			local mask = person.mask;&lt;br /&gt;
			local one;&lt;br /&gt;
			local sep_one = sep;&lt;br /&gt;
&lt;br /&gt;
			if utilities.is_set (maximum) and i &amp;gt; maximum then&lt;br /&gt;
				etal = true;&lt;br /&gt;
				break;&lt;br /&gt;
			end&lt;br /&gt;
			&lt;br /&gt;
			if mask then&lt;br /&gt;
				local n = tonumber (mask);										-- convert to a number if it can be converted; nil else&lt;br /&gt;
				if n then&lt;br /&gt;
					one = 0 ~= n and string.rep(&amp;quot;&amp;amp;mdash;&amp;quot;,n) or nil;			-- make a string of (n &amp;gt; 0) mdashes, nil else, to replace name&lt;br /&gt;
					person.link = nil;											-- don't create link to name if name is replaces with mdash string or has been set nil&lt;br /&gt;
				else&lt;br /&gt;
					one = mask;													-- replace name with mask text (must include name-list separator)&lt;br /&gt;
					sep_one = &amp;quot; &amp;quot;;												-- modify name-list separator&lt;br /&gt;
				end&lt;br /&gt;
			else&lt;br /&gt;
				one = person.last;												-- get surname&lt;br /&gt;
				local first = person.first										-- get given name&lt;br /&gt;
				if utilities.is_set (first) then&lt;br /&gt;
					if (&amp;quot;vanc&amp;quot; == format) then									-- if Vancouver format&lt;br /&gt;
						one = one:gsub ('%.', '');								-- remove periods from surnames (http://www.ncbi.nlm.nih.gov/books/NBK7271/box/A35029/)&lt;br /&gt;
						if not person.corporate and is_good_vanc_name (one, first) then		-- and name is all Latin characters; corporate authors not tested&lt;br /&gt;
							first = reduce_to_initials (first);					-- attempt to convert first name(s) to initials&lt;br /&gt;
						end&lt;br /&gt;
					end&lt;br /&gt;
					one = one .. namesep .. first;&lt;br /&gt;
				end&lt;br /&gt;
			end&lt;br /&gt;
			if utilities.is_set (person.link) then&lt;br /&gt;
				one = utilities.make_wikilink (person.link, one);				-- link author/editor&lt;br /&gt;
			end&lt;br /&gt;
			if one then															-- if &amp;lt;one&amp;gt; has a value (name, mdash replacement, or mask text replacement)&lt;br /&gt;
				table.insert (name_list, one);									-- add it to the list of names&lt;br /&gt;
				table.insert (name_list, sep_one);								-- add the proper name-list separator&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local count = #name_list / 2;												-- (number of names + number of separators) divided by 2&lt;br /&gt;
	if 0 &amp;lt; count then &lt;br /&gt;
		if 1 &amp;lt; count and not etal then&lt;br /&gt;
			if 'amp' == format or utilities.is_set (lastauthoramp) then			-- TODO: delete lastauthoramp after deprecation&lt;br /&gt;
				name_list[#name_list-2] = &amp;quot; &amp;amp; &amp;quot;;								-- replace last separator with ampersand text&lt;br /&gt;
			elseif 'and' == format then&lt;br /&gt;
				if 2 == count then&lt;br /&gt;
					name_list[#name_list-2] = cfg.presentation.sep_nl_and;		-- replace last separator with 'and' text&lt;br /&gt;
				else&lt;br /&gt;
					name_list[#name_list-2] = cfg.presentation.sep_nl_end;		-- replace last separator with '(sep) and' text&lt;br /&gt;
				end&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
		name_list[#name_list] = nil;											-- erase the last separator&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local result = table.concat (name_list);									-- construct list&lt;br /&gt;
	if etal and utilities.is_set (result) then									-- etal may be set by |display-authors=etal but we might not have a last-first list&lt;br /&gt;
		result = result .. sep .. ' ' .. cfg.messages['et al'];					-- we've got a last-first list and etal so add et al.&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	return result, count;														-- return name-list string and count of number of names (count used for editor names only)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; A N C H O R _ I D &amp;gt;------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Generates a CITEREF anchor ID if we have at least one name or a date.  Otherwise returns an empty string.&lt;br /&gt;
&lt;br /&gt;
namelist is one of the contributor-, author-, or editor-name lists chosen in that order.  year is Year or anchor_year.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function anchor_id (namelist, year)&lt;br /&gt;
	local names={};																-- a table for the one to four names and year&lt;br /&gt;
	for i,v in ipairs (namelist) do												-- loop through the list and take up to the first four last names&lt;br /&gt;
		names[i] = v.last &lt;br /&gt;
		if i == 4 then break end												-- if four then done&lt;br /&gt;
	end&lt;br /&gt;
	table.insert (names, year);													-- add the year at the end&lt;br /&gt;
	local id = table.concat(names);												-- concatenate names and year for CITEREF id&lt;br /&gt;
	if utilities.is_set (id) then												-- if concatenation is not an empty string&lt;br /&gt;
		return &amp;quot;CITEREF&amp;quot; .. id;													-- add the CITEREF portion&lt;br /&gt;
	else&lt;br /&gt;
		return '';																-- return an empty string; no reason to include CITEREF id in this citation&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; N A M E _ H A S _ E T A L &amp;gt;----------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Evaluates the content of name parameters (author, editor, etc.) for variations on the theme of et al.  If found,&lt;br /&gt;
the et al. is removed, a flag is set to true and the function returns the modified name and the flag.&lt;br /&gt;
&lt;br /&gt;
This function never sets the flag to false but returns it's previous state because it may have been set by&lt;br /&gt;
previous passes through this function or by the associated |display-&amp;lt;names&amp;gt;=etal parameter&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function name_has_etal (name, etal, nocat, param)&lt;br /&gt;
&lt;br /&gt;
	if utilities.is_set (name) then												-- name can be nil in which case just return&lt;br /&gt;
		local patterns = cfg.et_al_patterns;									--get patterns from configuration&lt;br /&gt;
		&lt;br /&gt;
		for _, pattern in ipairs (patterns) do									-- loop through all of the patterns&lt;br /&gt;
			if name:match (pattern) then										-- if this 'et al' pattern is found in name&lt;br /&gt;
				name = name:gsub (pattern, '');									-- remove the offending text&lt;br /&gt;
				etal = true;													-- set flag (may have been set previously here or by |display-&amp;lt;names&amp;gt;=etal)&lt;br /&gt;
				if not nocat then												-- no categorization for |vauthors=&lt;br /&gt;
					table.insert( z.message_tail, {utilities.set_message ('err_etal', {param})});	-- and set an error if not added&lt;br /&gt;
				end&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	return name, etal;&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; N A M E _ I S _ N U M E R I C &amp;gt;------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Add maint cat when name parameter value does not contain letters.  Does not catch mixed alphanumeric names so&lt;br /&gt;
|last=A. Green (1922-1987) does not get caught in the current version of this test but |first=(1888) is caught.&lt;br /&gt;
&lt;br /&gt;
returns nothing&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function name_is_numeric (name, list_name)&lt;br /&gt;
	if utilities.is_set (name) then&lt;br /&gt;
		if mw.ustring.match (name, '^[%A]+$') then								-- when name does not contain any letters&lt;br /&gt;
			utilities.set_message ('maint_numeric_names', cfg.special_case_translation [list_name]);	-- add a maint cat for this template&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; N A M E _ H A S _ E D _ M A R K U P &amp;gt;------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Evaluates the content of author and editor parameters for extraneous editor annotations: ed, ed., eds, (Ed.), etc.&lt;br /&gt;
These annotation do not belong in author parameters and are redundant in editor parameters.  If found, the function&lt;br /&gt;
adds the editor markup maintenance category.&lt;br /&gt;
&lt;br /&gt;
returns nothing&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function name_has_ed_markup (name, list_name)&lt;br /&gt;
	local patterns = cfg.editor_markup_patterns;								-- get patterns from configuration&lt;br /&gt;
&lt;br /&gt;
	if utilities.is_set (name) then&lt;br /&gt;
		for _, pattern in ipairs (patterns) do									-- spin through patterns table and&lt;br /&gt;
			if name:match (pattern) then&lt;br /&gt;
				utilities.set_message ('maint_extra_text_names', cfg.special_case_translation [list_name]);	-- add a maint cat for this template&lt;br /&gt;
				break;&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; N A M E _ H A S _ M U L T _ N A M E S &amp;gt;----------------------------------------&lt;br /&gt;
&lt;br /&gt;
Evaluates the content of last/surname (authors etc.) parameters for multiple names.  Multiple names are indicated&lt;br /&gt;
if there is more than one comma or any semicolons.  If found, the function adds the multiple name maintenance category.&lt;br /&gt;
&lt;br /&gt;
returns nothing&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function name_has_mult_names (name, list_name)&lt;br /&gt;
	local _, commas, semicolons;&lt;br /&gt;
	if utilities.is_set (name) then&lt;br /&gt;
		_, commas = name:gsub (',', '');										-- count the number of commas&lt;br /&gt;
		_, semicolons = name:gsub (';', '');									-- count the number of semicolons&lt;br /&gt;
		&lt;br /&gt;
		if 1 &amp;lt; commas or 0 &amp;lt; semicolons then												&lt;br /&gt;
			utilities.set_message ('maint_mult_names', cfg.special_case_translation [list_name]);	-- add a maint message&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; N A M E _ C H E C K S &amp;gt;--------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
This function calls various name checking functions used to validate the content of the various name-holding&lt;br /&gt;
parameters.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function name_checks (last, first, list_name)&lt;br /&gt;
	local accept_name;&lt;br /&gt;
&lt;br /&gt;
	if utilities.is_set (last) then&lt;br /&gt;
		last, accept_name = utilities.has_accept_as_written (last);				-- remove accept-this-as-written markup when it wraps all of &amp;lt;last&amp;gt;&lt;br /&gt;
		&lt;br /&gt;
		if not accept_name then													-- &amp;lt;last&amp;gt; not wrapped in accept-as-written markup&lt;br /&gt;
			name_has_mult_names (last, list_name);								-- check for multiple names in the parameter (last only)&lt;br /&gt;
			name_has_ed_markup (last, list_name);								-- check for extraneous 'editor' annotation&lt;br /&gt;
			name_is_numeric (last, list_name);									-- check for names that are compsed of digits and punctuation&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if utilities.is_set (first) then&lt;br /&gt;
		first, accept_name = utilities.has_accept_as_written (first);			-- remove accept-this-as-written markup when it wraps all of &amp;lt;first&amp;gt;&lt;br /&gt;
&lt;br /&gt;
		if not accept_name then														-- &amp;lt;first&amp;gt; not wrapped in accept-as-written markup&lt;br /&gt;
			name_has_ed_markup (first, list_name);								-- check for extraneous 'editor' annotation&lt;br /&gt;
			name_is_numeric (first, list_name);									-- check for names that are compsed of digits and punctuation&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	return last, first;															-- done&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; E X T R A C T _ N A M E S &amp;gt;----------------------------------------------------&lt;br /&gt;
Gets name list from the input arguments&lt;br /&gt;
&lt;br /&gt;
Searches through args in sequential order to find |lastn= and |firstn= parameters (or their aliases), and their matching link and mask parameters.&lt;br /&gt;
Stops searching when both |lastn= and |firstn= are not found in args after two sequential attempts: found |last1=, |last2=, and |last3= but doesn't&lt;br /&gt;
find |last4= and |last5= then the search is done.&lt;br /&gt;
&lt;br /&gt;
This function emits an error message when there is a |firstn= without a matching |lastn=.  When there are 'holes' in the list of last names, |last1= and |last3=&lt;br /&gt;
are present but |last2= is missing, an error message is emitted. |lastn= is not required to have a matching |firstn=.&lt;br /&gt;
&lt;br /&gt;
When an author or editor parameter contains some form of 'et al.', the 'et al.' is stripped from the parameter and a flag (etal) returned&lt;br /&gt;
that will cause list_people() to add the static 'et al.' text from Module:Citation/CS1/Configuration.  This keeps 'et al.' out of the &lt;br /&gt;
template's metadata.  When this occurs, the page is added to a maintenance category.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function extract_names(args, list_name)&lt;br /&gt;
	local names = {};															-- table of names&lt;br /&gt;
	local last;																	-- individual name components&lt;br /&gt;
	local first;&lt;br /&gt;
	local link;&lt;br /&gt;
	local mask;&lt;br /&gt;
	local i = 1;																-- loop counter/indexer&lt;br /&gt;
	local n = 1;																-- output table indexer&lt;br /&gt;
	local count = 0;															-- used to count the number of times we haven't found a |last= (or alias for authors, |editor-last or alias for editors)&lt;br /&gt;
	local etal = false;															-- return value set to true when we find some form of et al. in an author parameter&lt;br /&gt;
&lt;br /&gt;
	local last_alias, first_alias, link_alias;									-- selected parameter aliases used in error messaging&lt;br /&gt;
	while true do&lt;br /&gt;
		last, last_alias = utilities.select_one ( args, cfg.aliases[list_name .. '-Last'], 'err_redundant_parameters', i );		-- search through args for name components beginning at 1&lt;br /&gt;
		first, first_alias = utilities.select_one ( args, cfg.aliases[list_name .. '-First'], 'err_redundant_parameters', i );&lt;br /&gt;
		link, link_alias = utilities.select_one ( args, cfg.aliases[list_name .. '-Link'], 'err_redundant_parameters', i );&lt;br /&gt;
		mask = utilities.select_one ( args, cfg.aliases[list_name .. '-Mask'], 'err_redundant_parameters', i );&lt;br /&gt;
&lt;br /&gt;
		last, etal = name_has_etal (last, etal, false, last_alias);				-- find and remove variations on et al.&lt;br /&gt;
		first, etal = name_has_etal (first, etal, false, first_alias);			-- find and remove variations on et al.&lt;br /&gt;
		last, first = name_checks (last, first, list_name);						-- multiple names, extraneous annotation, etc. checks&lt;br /&gt;
		&lt;br /&gt;
		if first and not last then												-- if there is a firstn without a matching lastn&lt;br /&gt;
			local alias = first_alias:find ('given', 1, true) and 'given' or 'first';	-- get first or given form of the alias&lt;br /&gt;
			table.insert (z.message_tail, { utilities.set_message ( 'err_first_missing_last', {&lt;br /&gt;
				first_alias,													-- param name of alias missing its mate&lt;br /&gt;
				first_alias:gsub (alias, {['first'] = 'last', ['given'] = 'surname'}),	-- make param name appropriate to the alias form&lt;br /&gt;
				}, true ) } );													-- add this error message&lt;br /&gt;
		elseif not first and not last then										-- if both firstn and lastn aren't found, are we done?&lt;br /&gt;
			count = count + 1;													-- number of times we haven't found last and first&lt;br /&gt;
			if 2 &amp;lt;= count then													-- two missing names and we give up&lt;br /&gt;
				break;															-- normal exit or there is a two-name hole in the list; can't tell which&lt;br /&gt;
			end&lt;br /&gt;
		else																	-- we have last with or without a first&lt;br /&gt;
			local result;&lt;br /&gt;
			link = link_title_ok (link, link_alias, last, last_alias);			-- check for improper wiki-markup&lt;br /&gt;
			if first then&lt;br /&gt;
				link = link_title_ok (link, link_alias, first, first_alias);	-- check for improper wiki-markup&lt;br /&gt;
			end&lt;br /&gt;
&lt;br /&gt;
			names[n] = {last = last, first = first, link = link, mask = mask, corporate = false};	-- add this name to our names list (corporate for |vauthors= only)&lt;br /&gt;
			n = n + 1;															-- point to next location in the names table&lt;br /&gt;
			if 1 == count then													-- if the previous name was missing&lt;br /&gt;
				table.insert( z.message_tail, { utilities.set_message ( 'err_missing_name', {list_name:match (&amp;quot;(%w+)List&amp;quot;):lower(), i - 1}, true ) } );	-- add this error message&lt;br /&gt;
			end&lt;br /&gt;
			count = 0;															-- reset the counter, we're looking for two consecutive missing names&lt;br /&gt;
		end&lt;br /&gt;
		i = i + 1;																-- point to next args location&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	return names, etal;															-- all done, return our list of names and the etal flag&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; G E T _ I S O 6 3 9 _ C O D E &amp;gt;------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Validates language names provided in |language= parameter if not an ISO639-1 or 639-2 code.&lt;br /&gt;
&lt;br /&gt;
Returns the language name and associated two- or three-character code.  Because case of the source may be incorrect&lt;br /&gt;
or different from the case that WikiMedia uses, the name comparisons are done in lower case and when a match is&lt;br /&gt;
found, the Wikimedia version (assumed to be correct) is returned along with the code.  When there is no match, we&lt;br /&gt;
return the original language name string.&lt;br /&gt;
&lt;br /&gt;
mw.language.fetchLanguageNames(&amp;lt;local wiki language&amp;gt;, 'all') returns a list of languages that in some cases may include&lt;br /&gt;
extensions. For example, code 'cbk-zam' and its associated name 'Chavacano de Zamboanga' (MediaWiki does not support&lt;br /&gt;
code 'cbk' or name 'Chavacano'.  Most (all?) of these languages are not used a 'language' codes per se, rather they&lt;br /&gt;
are used as sub-domain names: cbk-zam.wikipedia.org.  A list of language names and codes supported by fetchLanguageNames()&lt;br /&gt;
can be found at Template:Citation Style documentation/language/doc&lt;br /&gt;
&lt;br /&gt;
Names that are included in the list will be found if that name is provided in the |language= parameter.  For example,&lt;br /&gt;
if |language=Chavacano de Zamboanga, that name will be found with the associated code 'cbk-zam'.  When names are found&lt;br /&gt;
and the associated code is not two or three characters, this function returns only the WikiMedia language name.&lt;br /&gt;
&lt;br /&gt;
Some language names have multiple entries under different codes:&lt;br /&gt;
	Aromanian has code rup and code roa-rup&lt;br /&gt;
When this occurs, this function returns the language name and the 2- or 3-character code&lt;br /&gt;
&lt;br /&gt;
Adapted from code taken from Module:Check ISO 639-1.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function get_iso639_code (lang, this_wiki_code)&lt;br /&gt;
	if cfg.lang_name_remap[lang:lower()] then									-- if there is a remapped name (because MediaWiki uses something that we don't think is correct)&lt;br /&gt;
		return cfg.lang_name_remap[lang:lower()][1], cfg.lang_name_remap[lang:lower()][2];	-- for this language 'name', return a possibly new name and appropriate code&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local ietf_code;															-- because some languages have both IETF-like codes and ISO 639-like codes&lt;br /&gt;
	local ietf_name;&lt;br /&gt;
	&lt;br /&gt;
	local langlc = mw.ustring.lower (lang);										-- lower-case version for comparisons&lt;br /&gt;
&lt;br /&gt;
	for code, name in pairs (cfg.languages) do									-- scan the list to see if we can find our language&lt;br /&gt;
		if langlc == mw.ustring.lower (name) then&lt;br /&gt;
			if 2 == #code or 3 == #code then									-- two- or three-character codes only; IETF extensions not supported&lt;br /&gt;
				return name, code;												-- so return the name and the code&lt;br /&gt;
			end&lt;br /&gt;
			ietf_code = code;													-- remember that we found an IETF-like code and save its name&lt;br /&gt;
			ietf_name = name;													-- but keep looking for a 2- or 3-char code&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
																				-- didn't find name with 2- or 3-char code; if IETF-like code found return&lt;br /&gt;
	return ietf_code and ietf_name or lang;										-- associated name; return original language text else&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; L A N G U A G E _ P A R A M E T E R &amp;gt;------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Gets language name from a provided two- or three-character ISO 639 code.  If a code is recognized by MediaWiki,&lt;br /&gt;
use the returned name; if not, then use the value that was provided with the language parameter.&lt;br /&gt;
&lt;br /&gt;
When |language= contains a recognized language (either code or name), the page is assigned to the category for&lt;br /&gt;
that code: Category:Norwegian-language sources (no).  For valid three-character code languages, the page is assigned&lt;br /&gt;
to the single category for '639-2' codes: Category:CS1 ISO 639-2 language sources.&lt;br /&gt;
&lt;br /&gt;
Languages that are the same as the local wiki are not categorized.  MediaWiki does not recognize three-character&lt;br /&gt;
equivalents of two-character codes: code 'ar' is recognized but code 'ara' is not.&lt;br /&gt;
&lt;br /&gt;
This function supports multiple languages in the form |language=nb, French, th where the language names or codes are&lt;br /&gt;
separated from each other by commas with optional space characters.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function language_parameter (lang)&lt;br /&gt;
	local code;																	-- the two- or three-character language code&lt;br /&gt;
	local name;																	-- the language name&lt;br /&gt;
	local language_list = {};													-- table of language names to be rendered&lt;br /&gt;
	local names_table = {};														-- table made from the value assigned to |language=&lt;br /&gt;
&lt;br /&gt;
	local this_wiki_name = mw.language.fetchLanguageName (cfg.this_wiki_code, cfg.this_wiki_code);	-- get this wiki's language name&lt;br /&gt;
&lt;br /&gt;
	names_table = mw.text.split (lang, '%s*,%s*');								-- names should be a comma separated list&lt;br /&gt;
&lt;br /&gt;
	for _, lang in ipairs (names_table) do										-- reuse lang&lt;br /&gt;
		name = cfg.lang_code_remap[lang:lower()];								-- first see if this is a code that is not supported by MediaWiki but is in remap&lt;br /&gt;
&lt;br /&gt;
		if name then															-- there was a remapped code so&lt;br /&gt;
			if not lang:match ('^%a%a%a?%-x%-%a+$') then						-- if not a private IETF tag&lt;br /&gt;
				lang = lang:gsub ('^(%a%a%a?)%-.*', '%1');						-- strip IETF tags from code&lt;br /&gt;
			end&lt;br /&gt;
		else&lt;br /&gt;
			lang = lang:gsub ('^(%a%a%a?)%-.*', '%1');							-- strip any IETF-like tags from code&lt;br /&gt;
			if 2 == lang:len() or 3 == lang:len() then							-- if two-or three-character code&lt;br /&gt;
				name = mw.language.fetchLanguageName (lang:lower(), cfg.this_wiki_code);	-- get language name if |language= is a proper code&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
		if utilities.is_set (name) then											-- if |language= specified a valid code&lt;br /&gt;
			code = lang:lower();												-- save it&lt;br /&gt;
		else&lt;br /&gt;
			name, code = get_iso639_code (lang, cfg.this_wiki_code);			-- attempt to get code from name (assign name here so that we are sure of proper capitalization)&lt;br /&gt;
		end&lt;br /&gt;
	&lt;br /&gt;
		if utilities.is_set (code) then											-- only 2- or 3-character codes&lt;br /&gt;
			name = cfg.lang_code_remap[code] or name;							-- override wikimedia when they misuse language codes/names&lt;br /&gt;
&lt;br /&gt;
			if cfg.this_wiki_code ~= code then									-- when the language is not the same as this wiki's language&lt;br /&gt;
				if 2 == code:len() then											-- and is a two-character code&lt;br /&gt;
					utilities.add_prop_cat ('foreign_lang_source' .. code, {name, code});	-- categorize it; code appended to allow for multiple language categorization&lt;br /&gt;
				else															-- or is a recognized language (but has a three-character code)&lt;br /&gt;
					utilities.add_prop_cat ('foreign_lang_source_2' .. code, {code});		-- categorize it differently TODO: support multiple three-character code categories per cs1|2 template&lt;br /&gt;
				end&lt;br /&gt;
			elseif cfg.local_lang_cat_enable then								-- when the language and this wiki's language are the same and categorization is enabled&lt;br /&gt;
				utilities.add_prop_cat ('local_lang_source', {name, code});		-- categorize it&lt;br /&gt;
			end&lt;br /&gt;
		else&lt;br /&gt;
			utilities.set_message ('maint_unknown_lang');						-- add maint category if not already added&lt;br /&gt;
		end&lt;br /&gt;
		&lt;br /&gt;
		table.insert (language_list, name);&lt;br /&gt;
		name = '';																-- so we can reuse it&lt;br /&gt;
	end&lt;br /&gt;
 &lt;br /&gt;
	name = utilities.make_sep_list (#language_list, language_list);&lt;br /&gt;
&lt;br /&gt;
	if this_wiki_name == name then&lt;br /&gt;
		return '';																-- if one language and that language is this wiki's return an empty string (no annotation)&lt;br /&gt;
	end&lt;br /&gt;
	return (&amp;quot; &amp;quot; .. wrap_msg ('language', name));								-- otherwise wrap with '(in ...)'&lt;br /&gt;
	--[[ TODO: should only return blank or name rather than full list&lt;br /&gt;
	so we can clean up the bunched parenthetical elements Language, Type, Format&lt;br /&gt;
	]]&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; S E T _ C S 1 _ S T Y L E &amp;gt;----------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Set style settings for CS1 citation templates. Returns separator and postscript settings&lt;br /&gt;
At en.wiki, for cs1:&lt;br /&gt;
	ps gets:	'.'&lt;br /&gt;
	sep gets:	'.'&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function set_cs1_style (ps)&lt;br /&gt;
	if not utilities.is_set (ps) then											-- unless explicitly set to something&lt;br /&gt;
		ps = cfg.presentation['ps_cs1'];										-- terminate the rendered citation&lt;br /&gt;
	end&lt;br /&gt;
	return cfg.presentation['sep_cs1'], ps;										-- element separator&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; S E T _ C S 2 _ S T Y L E &amp;gt;----------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Set style settings for CS2 citation templates. Returns separator, postscript, ref settings&lt;br /&gt;
At en.wiki, for cs2:&lt;br /&gt;
	ps gets:	'' (empty string - no terminal punctuation)&lt;br /&gt;
	sep gets:	','&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function set_cs2_style (ps, ref)&lt;br /&gt;
	if not utilities.is_set (ps) then											-- if |postscript= has not been set, set cs2 default&lt;br /&gt;
		ps = cfg.presentation['ps_cs2'];										-- terminate the rendered citation&lt;br /&gt;
	end&lt;br /&gt;
	if not utilities.is_set (ref) then											-- if |ref= is not set&lt;br /&gt;
		ref = &amp;quot;harv&amp;quot;;															-- set default |ref=harv&lt;br /&gt;
	end&lt;br /&gt;
	return cfg.presentation['sep_cs2'], ps, ref;								-- element separator&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; G E T _ S E T T I N G S _ F R O M _ C I T E _ C L A S S &amp;gt;----------------------&lt;br /&gt;
&lt;br /&gt;
When |mode= is not set or when its value is invalid, use config.CitationClass and parameter values to establish&lt;br /&gt;
rendered style.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function get_settings_from_cite_class (ps, ref, cite_class)&lt;br /&gt;
	local sep;&lt;br /&gt;
	if (cite_class == &amp;quot;citation&amp;quot;) then											-- for citation templates (CS2)&lt;br /&gt;
		sep, ps, ref = set_cs2_style (ps, ref);&lt;br /&gt;
	else																		-- not a citation template so CS1&lt;br /&gt;
		sep, ps = set_cs1_style (ps);&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	return sep, ps, ref															-- return them all&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; S E T _ S T Y L E &amp;gt;------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Establish basic style settings to be used when rendering the citation.  Uses |mode= if set and valid or uses&lt;br /&gt;
config.CitationClass from the template's #invoke: to establish style.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function set_style (mode, ps, ref, cite_class)&lt;br /&gt;
	local sep;&lt;br /&gt;
	if 'cs2' == mode then														-- if this template is to be rendered in CS2 (citation) style&lt;br /&gt;
		sep, ps, ref = set_cs2_style (ps, ref);&lt;br /&gt;
	elseif 'cs1' == mode then													-- if this template is to be rendered in CS1 (cite xxx) style&lt;br /&gt;
		sep, ps = set_cs1_style (ps);&lt;br /&gt;
	else																		-- anything but cs1 or cs2&lt;br /&gt;
		sep, ps, ref = get_settings_from_cite_class (ps, ref, cite_class);		-- get settings based on the template's CitationClass&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if cfg.keywords_xlate[ps:lower()] == 'none' then							-- if assigned value is 'none' then&lt;br /&gt;
		ps = '';																-- set to empty string&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	return sep, ps, ref&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[=[-------------------------&amp;lt; I S _ P D F &amp;gt;------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Determines if a URL has the file extension that is one of the PDF file extensions used by [[MediaWiki:Common.css]] when&lt;br /&gt;
applying the PDF icon to external links.&lt;br /&gt;
&lt;br /&gt;
returns true if file extension is one of the recognized extensions, else false&lt;br /&gt;
&lt;br /&gt;
]=]&lt;br /&gt;
&lt;br /&gt;
local function is_pdf (url)&lt;br /&gt;
	return url:match ('%.pdf$') or url:match ('%.PDF$') or&lt;br /&gt;
		url:match ('%.pdf[%?#]') or url:match ('%.PDF[%?#]') or&lt;br /&gt;
		url:match ('%.PDF&amp;amp;#035') or url:match ('%.pdf&amp;amp;#035');&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; S T Y L E _ F O R M A T &amp;gt;------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Applies CSS style to |format=, |chapter-format=, etc.  Also emits an error message if the format parameter does&lt;br /&gt;
not have a matching URL parameter.  If the format parameter is not set and the URL contains a file extension that&lt;br /&gt;
is recognized as a PDF document by MediaWiki's commons.css, this code will set the format parameter to (PDF) with&lt;br /&gt;
the appropriate styling.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function style_format (format, url, fmt_param, url_param)&lt;br /&gt;
	if utilities.is_set (format) then&lt;br /&gt;
		format = utilities.wrap_style ('format', format);						-- add leading space, parentheses, resize&lt;br /&gt;
		if not utilities.is_set (url) then&lt;br /&gt;
			format = format .. ' ' .. utilities.set_message ( 'err_format_missing_url', {fmt_param, url_param} );	-- add an error message&lt;br /&gt;
		end&lt;br /&gt;
	elseif is_pdf (url) then													-- format is not set so if URL is a PDF file then&lt;br /&gt;
		format = utilities.wrap_style ('format', 'PDF');						-- set format to PDF&lt;br /&gt;
	else&lt;br /&gt;
		format = '';															-- empty string for concatenation&lt;br /&gt;
	end&lt;br /&gt;
	return format;&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; G E T _ D I S P L A Y _ N A M E S &amp;gt;--------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Returns a number that defines the number of names displayed for author and editor name lists and a Boolean flag&lt;br /&gt;
to indicate when et al. should be appended to the name list.&lt;br /&gt;
&lt;br /&gt;
When the value assigned to |display-xxxxors= is a number greater than or equal to zero, return the number and&lt;br /&gt;
the previous state of the 'etal' flag (false by default but may have been set to true if the name list contains&lt;br /&gt;
some variant of the text 'et al.').&lt;br /&gt;
&lt;br /&gt;
When the value assigned to |display-xxxxors= is the keyword 'etal', return a number that is one greater than the&lt;br /&gt;
number of authors in the list and set the 'etal' flag true.  This will cause the list_people() to display all of&lt;br /&gt;
the names in the name list followed by 'et al.'&lt;br /&gt;
&lt;br /&gt;
In all other cases, returns nil and the previous state of the 'etal' flag.&lt;br /&gt;
&lt;br /&gt;
inputs:&lt;br /&gt;
	max: A['DisplayAuthors'] or A['DisplayEditors']; a number or some flavor of etal&lt;br /&gt;
	count: #a or #e&lt;br /&gt;
	list_name: 'authors' or 'editors'&lt;br /&gt;
	etal: author_etal or editor_etal&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function get_display_names (max, count, list_name, etal)&lt;br /&gt;
	if utilities.is_set (max) then&lt;br /&gt;
		if 'etal' == max:lower():gsub(&amp;quot;[ '%.]&amp;quot;, '') then						-- the :gsub() portion makes 'etal' from a variety of 'et al.' spellings and stylings&lt;br /&gt;
			max = count + 1;													-- number of authors + 1 so display all author name plus et al.&lt;br /&gt;
			etal = true;														-- overrides value set by extract_names()&lt;br /&gt;
		elseif max:match ('^%d+$') then											-- if is a string of numbers&lt;br /&gt;
			max = tonumber (max);												-- make it a number&lt;br /&gt;
			if max &amp;gt;= count then												-- if |display-xxxxors= value greater than or equal to number of authors/editors&lt;br /&gt;
				table.insert( z.message_tail, {utilities.set_message ('err_disp_name', {cfg.special_case_translation [list_name], max}, true)});	-- add error message&lt;br /&gt;
				max = nil;&lt;br /&gt;
			end&lt;br /&gt;
		else																	-- not a valid keyword or number&lt;br /&gt;
			table.insert( z.message_tail, {utilities.set_message ('err_disp_name', {cfg.special_case_translation [list_name], max}, true)});		-- add error message&lt;br /&gt;
			max = nil;															-- unset; as if |display-xxxxors= had not been set&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	return max, etal;&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; E X T R A _ T E X T _ I N _ P A G E _ C H E C K &amp;gt;------------------------------&lt;br /&gt;
&lt;br /&gt;
Adds page to Category:CS1 maint: extra text if |page= or |pages= has what appears to be some form of p. or pp. &lt;br /&gt;
abbreviation in the first characters of the parameter content.&lt;br /&gt;
&lt;br /&gt;
check Page and Pages for extraneous p, p., pp, and pp. at start of parameter value:&lt;br /&gt;
	good pattern: '^P[^%.P%l]' matches when |page(s)= begins PX or P# but not Px where x and X are letters and # is a dgiit&lt;br /&gt;
	bad pattern: '^[Pp][Pp]' matches matches when |page(s)= begins pp or pP or Pp or PP&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function extra_text_in_page_check (page)&lt;br /&gt;
	local good_pattern = '^P[^%.Pp]';											-- ok to begin with uppercase P: P7 (pg 7 of section P) but not p123 (page 123) TODO: add Gg for PG or Pg?&lt;br /&gt;
	local bad_pattern = '^[Pp]?[Pp]%.?[ %d]';&lt;br /&gt;
&lt;br /&gt;
	if not page:match (good_pattern) and (page:match (bad_pattern) or  page:match ('^[Pp]ages?')) then&lt;br /&gt;
		utilities.set_message ('maint_extra_text');								-- add maint cat;&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[=[-------------------------&amp;lt; G E T _ V _ N A M E _ T A B L E &amp;gt;----------------------------------------------&lt;br /&gt;
&lt;br /&gt;
split apart a |vauthors= or |veditors= parameter.  This function allows for corporate names, wrapped in doubled&lt;br /&gt;
parentheses to also have commas; in the old version of the code, the doubled parentheses were included in the&lt;br /&gt;
rendered citation and in the metadata.  Individual author names may be wikilinked&lt;br /&gt;
&lt;br /&gt;
	|vauthors=Jones AB, [[E. B. White|White EB]], ((Black, Brown, and Co.))&lt;br /&gt;
&lt;br /&gt;
]=]&lt;br /&gt;
&lt;br /&gt;
local function get_v_name_table (vparam, output_table, output_link_table)&lt;br /&gt;
	local name_table = mw.text.split(vparam, &amp;quot;%s*,%s*&amp;quot;);						-- names are separated by commas&lt;br /&gt;
	local wl_type, label, link;													-- wl_type not used here; just a place holder&lt;br /&gt;
	&lt;br /&gt;
	local i = 1;&lt;br /&gt;
	&lt;br /&gt;
	while name_table[i] do&lt;br /&gt;
		if name_table[i]:match ('^%(%(.*[^%)][^%)]$') then						-- first segment of corporate with one or more commas; this segment has the opening doubled parentheses&lt;br /&gt;
			local name = name_table[i];&lt;br /&gt;
			i = i + 1;																-- bump indexer to next segment&lt;br /&gt;
			while name_table[i] do&lt;br /&gt;
				name = name .. ', ' .. name_table[i];							-- concatenate with previous segments&lt;br /&gt;
				if name_table[i]:match ('^.*%)%)$') then						-- if this table member has the closing doubled parentheses&lt;br /&gt;
					break;														-- and done reassembling so&lt;br /&gt;
				end&lt;br /&gt;
				i = i + 1;														-- bump indexer&lt;br /&gt;
			end&lt;br /&gt;
			table.insert (output_table, name);									-- and add corporate name to the output table&lt;br /&gt;
			table.insert (output_link_table, '');								-- no wikilink&lt;br /&gt;
		else&lt;br /&gt;
			wl_type, label, link = utilities.is_wikilink (name_table[i]);		-- wl_type is: 0, no wl (text in label variable); 1, [[D]]; 2, [[L|D]]&lt;br /&gt;
			table.insert (output_table, label);									-- add this name&lt;br /&gt;
			if 1 == wl_type then&lt;br /&gt;
				table.insert (output_link_table, label);						-- simple wikilink [[D]]&lt;br /&gt;
			else&lt;br /&gt;
				table.insert (output_link_table, link);							-- no wikilink or [[L|D]]; add this link if there is one, else empty string&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
		i = i + 1;&lt;br /&gt;
	end	&lt;br /&gt;
	return output_table;&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; P A R S E _ V A U T H O R S _ V E D I T O R S &amp;gt;--------------------------------&lt;br /&gt;
&lt;br /&gt;
This function extracts author / editor names from |vauthors= or |veditors= and finds matching |xxxxor-maskn= and&lt;br /&gt;
|xxxxor-linkn= in args.  It then returns a table of assembled names just as extract_names() does.&lt;br /&gt;
&lt;br /&gt;
Author / editor names in |vauthors= or |veditors= must be in Vancouver system style. Corporate or institutional names&lt;br /&gt;
may sometimes be required and because such names will often fail the is_good_vanc_name() and other format compliance&lt;br /&gt;
tests, are wrapped in doubled parentheses ((corporate name)) to suppress the format tests.&lt;br /&gt;
&lt;br /&gt;
Supports generational suffixes Jr, 2nd, 3rd, 4th–6th.&lt;br /&gt;
&lt;br /&gt;
This function sets the Vancouver error when a required comma is missing and when there is a space between an author's initials.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function parse_vauthors_veditors (args, vparam, list_name)&lt;br /&gt;
	local names = {};															-- table of names assembled from |vauthors=, |author-maskn=, |author-linkn=&lt;br /&gt;
	local v_name_table = {};&lt;br /&gt;
	local v_link_table = {};													-- when name is wikilinked, targets go in this table&lt;br /&gt;
	local etal = false;															-- return value set to true when we find some form of et al. vauthors parameter&lt;br /&gt;
	local last, first, link, mask, suffix;&lt;br /&gt;
	local corporate = false;&lt;br /&gt;
&lt;br /&gt;
	vparam, etal = name_has_etal (vparam, etal, true);							-- find and remove variations on et al. do not categorize (do it here because et al. might have a period)&lt;br /&gt;
	v_name_table = get_v_name_table (vparam, v_name_table, v_link_table);		-- names are separated by commas&lt;br /&gt;
&lt;br /&gt;
	for i, v_name in ipairs(v_name_table) do&lt;br /&gt;
		first = '';																-- set to empty string for concatenation and because it may have been set for previous author/editor&lt;br /&gt;
		local accept_name;&lt;br /&gt;
		v_name, accept_name = utilities.has_accept_as_written (v_name);			-- remove accept-this-as-written markup when it wraps all of &amp;lt;v_name&amp;gt;&lt;br /&gt;
&lt;br /&gt;
--		if v_name:match ('^%(%(.+%)%)$') then									-- corporate authors are wrapped in doubled parentheses to suppress vanc formatting and error detection&lt;br /&gt;
--			last = v_name:match ('^%(%((.+)%)%)$')								-- remove doubled parentheses&lt;br /&gt;
		if accept_name then&lt;br /&gt;
			last = v_name;&lt;br /&gt;
			corporate = true;													-- flag used in list_people()&lt;br /&gt;
		elseif string.find(v_name, &amp;quot;%s&amp;quot;) then&lt;br /&gt;
			if v_name:find('[;%.]') then										-- look for commonly occurring punctuation characters; &lt;br /&gt;
				add_vanc_error (cfg.err_msg_supl.punctuation);&lt;br /&gt;
			end&lt;br /&gt;
			local lastfirstTable = {}&lt;br /&gt;
			lastfirstTable = mw.text.split(v_name, &amp;quot;%s+&amp;quot;)&lt;br /&gt;
			first = table.remove(lastfirstTable);								-- removes and returns value of last element in table which should be initials or generational suffix&lt;br /&gt;
&lt;br /&gt;
			if not mw.ustring.match (first, '^%u+$') then						-- mw.ustring here so that later we will catch non-Latin characters&lt;br /&gt;
				suffix = first;													-- not initials so assume that whatever we got is a generational suffix&lt;br /&gt;
				first = table.remove(lastfirstTable);							-- get what should be the initials from the table&lt;br /&gt;
			end&lt;br /&gt;
			last = table.concat(lastfirstTable, ' ')							-- returns a string that is the concatenation of all other names that are not initials and generational suffix&lt;br /&gt;
			if not utilities.is_set (last) then&lt;br /&gt;
				first = '';														-- unset&lt;br /&gt;
				last = v_name;													-- last empty because something wrong with first&lt;br /&gt;
				add_vanc_error (cfg.err_msg_supl.name);&lt;br /&gt;
			end&lt;br /&gt;
			if mw.ustring.match (last, '%a+%s+%u+%s+%a+') then&lt;br /&gt;
				add_vanc_error (cfg.err_msg_supl['missing comma']);				-- matches last II last; the case when a comma is missing&lt;br /&gt;
			end&lt;br /&gt;
			if mw.ustring.match (v_name, ' %u %u$') then						-- this test is in the wrong place TODO: move or replace with a more appropriate test&lt;br /&gt;
				add_vanc_error (cfg.err_msg_supl.name);							-- matches a space between two initials&lt;br /&gt;
			end&lt;br /&gt;
		else&lt;br /&gt;
			last = v_name;														-- last name or single corporate name?  Doesn't support multiword corporate names? do we need this?&lt;br /&gt;
		end&lt;br /&gt;
		&lt;br /&gt;
		if utilities.is_set (first) then&lt;br /&gt;
			if not mw.ustring.match (first, &amp;quot;^%u?%u$&amp;quot;) then						-- first shall contain one or two upper-case letters, nothing else&lt;br /&gt;
				add_vanc_error (cfg.err_msg_supl.initials);						-- too many initials; mixed case initials (which may be ok Romanization); hyphenated initials&lt;br /&gt;
			end&lt;br /&gt;
			is_good_vanc_name (last, first, suffix);							-- check first and last before restoring the suffix which may have a non-Latin digit&lt;br /&gt;
			if utilities.is_set (suffix) then&lt;br /&gt;
				first = first .. ' ' .. suffix;									-- if there was a suffix concatenate with the initials&lt;br /&gt;
				suffix = '';													-- unset so we don't add this suffix to all subsequent names&lt;br /&gt;
			end&lt;br /&gt;
		else&lt;br /&gt;
			if not corporate then&lt;br /&gt;
				is_good_vanc_name (last, '');&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
		link = utilities.select_one ( args, cfg.aliases[list_name .. '-Link'], 'err_redundant_parameters', i ) or v_link_table[i];&lt;br /&gt;
		mask = utilities.select_one ( args, cfg.aliases[list_name .. '-Mask'], 'err_redundant_parameters', i );&lt;br /&gt;
		names[i] = {last = last, first = first, link = link, mask = mask, corporate = corporate};		-- add this assembled name to our names list&lt;br /&gt;
	end&lt;br /&gt;
	return names, etal;															-- all done, return our list of names&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; S E L E C T _ A U T H O R _ E D I T O R _ S O U R C E &amp;gt;------------------------&lt;br /&gt;
&lt;br /&gt;
Select one of |authors=, |authorn= / |lastn / firstn=, or |vauthors= as the source of the author name list or&lt;br /&gt;
select one of |editors=, |editorn= / editor-lastn= / |editor-firstn= or |veditors= as the source of the editor name list.&lt;br /&gt;
&lt;br /&gt;
Only one of these appropriate three will be used.  The hierarchy is: |authorn= (and aliases) highest and |authors= lowest and&lt;br /&gt;
similarly, |editorn= (and aliases) highest and |editors= lowest&lt;br /&gt;
&lt;br /&gt;
When looking for |authorn= / |editorn= parameters, test |xxxxor1= and |xxxxor2= (and all of their aliases); stops after the second&lt;br /&gt;
test which mimicks the test used in extract_names() when looking for a hole in the author name list.  There may be a better&lt;br /&gt;
way to do this, I just haven't discovered what that way is.&lt;br /&gt;
&lt;br /&gt;
Emits an error message when more than one xxxxor name source is provided.&lt;br /&gt;
&lt;br /&gt;
In this function, vxxxxors = vauthors or veditors; xxxxors = authors or editors as appropriate.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function select_author_editor_source (vxxxxors, xxxxors, args, list_name)&lt;br /&gt;
	local lastfirst = false;&lt;br /&gt;
	if utilities.select_one ( args, cfg.aliases[list_name .. '-Last'], 'none', 1 ) or		-- do this twice in case we have a |first1= without a |last1=; this ...&lt;br /&gt;
		utilities.select_one ( args, cfg.aliases[list_name .. '-First'], 'none', 1 ) or		-- ... also catches the case where |first= is used with |vauthors=&lt;br /&gt;
		utilities.select_one ( args, cfg.aliases[list_name .. '-Last'], 'none', 2 ) or&lt;br /&gt;
		utilities.select_one ( args, cfg.aliases[list_name .. '-First'], 'none', 2 ) then&lt;br /&gt;
			lastfirst = true;&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if (utilities.is_set (vxxxxors) and true == lastfirst) or					-- these are the three error conditions&lt;br /&gt;
		(utilities.is_set (vxxxxors) and utilities.is_set (xxxxors)) or&lt;br /&gt;
		(true == lastfirst and utilities.is_set (xxxxors)) then&lt;br /&gt;
			local err_name;&lt;br /&gt;
			if 'AuthorList' == list_name then									-- figure out which name should be used in error message&lt;br /&gt;
				err_name = 'author';&lt;br /&gt;
			else&lt;br /&gt;
				err_name = 'editor';&lt;br /&gt;
			end&lt;br /&gt;
			table.insert( z.message_tail, { utilities.set_message ( 'err_redundant_parameters',&lt;br /&gt;
				{err_name .. '-name-list parameters'}, true ) } );				-- add error message&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if true == lastfirst then return 1 end;										-- return a number indicating which author name source to use&lt;br /&gt;
	if utilities.is_set (vxxxxors) then return 2 end;&lt;br /&gt;
	if utilities.is_set (xxxxors) then return 3 end;&lt;br /&gt;
	return 1;																	-- no authors so return 1; this allows missing author name test to run in case there is a first without last &lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; I S _ V A L I D _ P A R A M E T E R _ V A L U E &amp;gt;------------------------------&lt;br /&gt;
&lt;br /&gt;
This function is used to validate a parameter's assigned value for those parameters that have only a limited number&lt;br /&gt;
of allowable values (yes, y, true, live, dead, etc.).  When the parameter value has not been assigned a value (missing&lt;br /&gt;
or empty in the source template) the function returns the value specified by ret_val.  If the parameter value is one&lt;br /&gt;
of the list of allowed values returns the translated value; else, emits an error message and returns the value&lt;br /&gt;
specified by ret_val.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function is_valid_parameter_value (value, name, possible, ret_val)&lt;br /&gt;
	if not utilities.is_set (value) then&lt;br /&gt;
		return ret_val;															-- an empty parameter is ok&lt;br /&gt;
	elseif utilities.in_array (value, possible) then&lt;br /&gt;
		return cfg.keywords_xlate[value];										-- return translation of parameter keyword&lt;br /&gt;
	else&lt;br /&gt;
		table.insert( z.message_tail, { utilities.set_message ( 'err_invalid_param_val', {name, value}, true ) } );	-- not an allowed value so add error message&lt;br /&gt;
		return ret_val;&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; T E R M I N A T E _ N A M E _ L I S T &amp;gt;----------------------------------------&lt;br /&gt;
&lt;br /&gt;
This function terminates a name list (author, contributor, editor) with a separator character (sepc) and a space&lt;br /&gt;
when the last character is not a sepc character or when the last three characters are not sepc followed by two&lt;br /&gt;
closing square brackets (close of a wikilink).  When either of these is true, the name_list is terminated with a&lt;br /&gt;
single space character.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function terminate_name_list (name_list, sepc)&lt;br /&gt;
	if (string.sub (name_list, -3, -1) == sepc .. '. ') then					-- if already properly terminated&lt;br /&gt;
		return name_list;														-- just return the name list&lt;br /&gt;
	elseif (string.sub (name_list, -1, -1) == sepc) or (string.sub (name_list, -3, -1) == sepc .. ']]') then	-- if last name in list ends with sepc char&lt;br /&gt;
		return name_list .. &amp;quot; &amp;quot;;												-- don't add another&lt;br /&gt;
	else&lt;br /&gt;
		return name_list .. sepc .. ' ';										-- otherwise terminate the name list&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[-------------------------&amp;lt; F O R M A T _ V O L U M E _ I S S U E &amp;gt;----------------------------------------&lt;br /&gt;
&lt;br /&gt;
returns the concatenation of the formatted volume and issue parameters as a single string; or formatted volume&lt;br /&gt;
or formatted issue, or an empty string if neither are set.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
	&lt;br /&gt;
local function format_volume_issue (volume, issue, cite_class, origin, sepc, lower)&lt;br /&gt;
	if not utilities.is_set (volume) and not utilities.is_set (issue) then&lt;br /&gt;
		return '';&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	if 'magazine' == cite_class or (utilities.in_array (cite_class, {'citation', 'map'}) and 'magazine' == origin) then&lt;br /&gt;
		if utilities.is_set (volume) and utilities.is_set (issue) then&lt;br /&gt;
			return wrap_msg ('vol-no', {sepc, volume, issue}, lower);&lt;br /&gt;
		elseif utilities.is_set (volume) then&lt;br /&gt;
			return wrap_msg ('vol', {sepc, volume}, lower);&lt;br /&gt;
		else&lt;br /&gt;
			return wrap_msg ('issue', {sepc, issue}, lower);&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if 'podcast' == cite_class and utilities.is_set (issue) then&lt;br /&gt;
		return wrap_msg ('issue', {sepc, issue}, lower);&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local vol = '';																-- here for all cites except magazine&lt;br /&gt;
		&lt;br /&gt;
	if utilities.is_set (volume) then&lt;br /&gt;
		if volume:match ('^[MDCLXVI]+$') or volume:match ('^%d+$') then			-- volume value is all digits or all uppercase Roman numerals&lt;br /&gt;
			vol = utilities.substitute (cfg.presentation['vol-bold'], {sepc, hyphen_to_dash(volume)});	-- render in bold face&lt;br /&gt;
		elseif (4 &amp;lt; mw.ustring.len(volume)) then								-- not all digits or Roman numerals and longer than 4 characters&lt;br /&gt;
			vol = utilities.substitute (cfg.messages['j-vol'], {sepc, volume});	-- not bold&lt;br /&gt;
			utilities.add_prop_cat ('long_vol');&lt;br /&gt;
		else																	-- four or less characters&lt;br /&gt;
			vol = utilities.substitute (cfg.presentation['vol-bold'], {sepc, hyphen_to_dash(volume)});	-- bold&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	if utilities.is_set (issue) then&lt;br /&gt;
		return vol .. utilities.substitute (cfg.messages['j-issue'], issue);&lt;br /&gt;
	end&lt;br /&gt;
	return vol;&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[-------------------------&amp;lt; F O R M A T _ P A G E S _ S H E E T S &amp;gt;-----------------------------------------&lt;br /&gt;
&lt;br /&gt;
adds static text to one of |page(s)= or |sheet(s)= values and returns it with all of the others set to empty strings.&lt;br /&gt;
The return order is:&lt;br /&gt;
	page, pages, sheet, sheets&lt;br /&gt;
&lt;br /&gt;
Singular has priority over plural when both are provided.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function format_pages_sheets (page, pages, sheet, sheets, cite_class, origin, sepc, nopp, lower)&lt;br /&gt;
	if 'map' == cite_class then													-- only cite map supports sheet(s) as in-source locators&lt;br /&gt;
		if utilities.is_set (sheet) then&lt;br /&gt;
			if 'journal' == origin then&lt;br /&gt;
				return '', '', wrap_msg ('j-sheet', sheet, lower), '';&lt;br /&gt;
			else&lt;br /&gt;
				return '', '', wrap_msg ('sheet', {sepc, sheet}, lower), '';&lt;br /&gt;
			end&lt;br /&gt;
		elseif utilities.is_set (sheets) then&lt;br /&gt;
			if 'journal' == origin then&lt;br /&gt;
				return '', '', '', wrap_msg ('j-sheets', sheets, lower);&lt;br /&gt;
			else&lt;br /&gt;
				return '', '', '', wrap_msg ('sheets', {sepc, sheets}, lower);&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local is_journal = 'journal' == cite_class or (utilities.in_array (cite_class, {'citation', 'map', 'interview'}) and 'journal' == origin);&lt;br /&gt;
	&lt;br /&gt;
	if utilities.is_set (page) then&lt;br /&gt;
		if is_journal then&lt;br /&gt;
			return utilities.substitute (cfg.messages['j-page(s)'], page), '', '', '';&lt;br /&gt;
		elseif not nopp then&lt;br /&gt;
			return utilities.substitute (cfg.messages['p-prefix'], {sepc, page}), '', '', '';&lt;br /&gt;
		else&lt;br /&gt;
			return utilities.substitute (cfg.messages['nopp'], {sepc, page}), '', '', '';&lt;br /&gt;
		end&lt;br /&gt;
	elseif utilities.is_set (pages) then&lt;br /&gt;
		if is_journal then&lt;br /&gt;
			return utilities.substitute (cfg.messages['j-page(s)'], pages), '', '', '';&lt;br /&gt;
		elseif tonumber(pages) ~= nil and not nopp then							-- if pages is only digits, assume a single page number&lt;br /&gt;
			return '', utilities.substitute (cfg.messages['p-prefix'], {sepc, pages}), '', '';&lt;br /&gt;
		elseif not nopp then&lt;br /&gt;
			return '', utilities.substitute (cfg.messages['pp-prefix'], {sepc, pages}), '', '';&lt;br /&gt;
		else&lt;br /&gt;
			return '', utilities.substitute (cfg.messages['nopp'], {sepc, pages}), '', '';&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	return '', '', '', '';														-- return empty strings&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; I N S O U R C E _ L O C _ G E T &amp;gt;----------------------------------------------&lt;br /&gt;
&lt;br /&gt;
returns one of the in-source locators: page, pages, or at. &lt;br /&gt;
&lt;br /&gt;
If any of these are interwiki links to Wikisource, returns the label portion of the interwiki-link as plain text&lt;br /&gt;
for use in COinS.  This COinS thing is done because here we convert an interwiki-link to and external link and&lt;br /&gt;
add an icon span around that; get_coins_pages() doesn't know about the span.  TODO: should it?  &lt;br /&gt;
&lt;br /&gt;
TODO: add support for sheet and sheets?; streamline;&lt;br /&gt;
&lt;br /&gt;
TODO: make it so that this function returns only one of the three as the single in-source (the return value assigned&lt;br /&gt;
to a new name)?&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function insource_loc_get (page, pages, at)&lt;br /&gt;
	local ws_url, ws_label, coins_pages, L;										-- for Wikisource interwiki-links; TODO: this corrupts page metadata (span remains in place after cleanup; fix there?)&lt;br /&gt;
&lt;br /&gt;
	if utilities.is_set (page) then&lt;br /&gt;
		if utilities.is_set (pages) or utilities.is_set (at) then&lt;br /&gt;
			pages = '';															-- unset the others&lt;br /&gt;
			at = '';&lt;br /&gt;
		end&lt;br /&gt;
		extra_text_in_page_check (page);										-- add this page to maint cat if |page= value begins with what looks like p. or pp.&lt;br /&gt;
&lt;br /&gt;
		ws_url, ws_label, L = wikisource_url_make (page);						-- make ws URL from |page= interwiki link; link portion L becomes tooltip label&lt;br /&gt;
		if ws_url then&lt;br /&gt;
			page = external_link (ws_url, ws_label .. '&amp;amp;nbsp;', 'ws link in page');	-- space char after label to move icon away from in-source text; TODO: a better way to do this?&lt;br /&gt;
			page = utilities.substitute (cfg.presentation['interwiki-icon'], {cfg.presentation['class-wikisource'], L, page});&lt;br /&gt;
			coins_pages = ws_label;&lt;br /&gt;
		end&lt;br /&gt;
	elseif utilities.is_set (pages) then&lt;br /&gt;
		if utilities.is_set (at) then&lt;br /&gt;
			at = '';															-- unset&lt;br /&gt;
		end&lt;br /&gt;
		extra_text_in_page_check (pages);										-- add this page to maint cat if |pages= value begins with what looks like p. or pp.&lt;br /&gt;
&lt;br /&gt;
		ws_url, ws_label, L = wikisource_url_make (pages);						-- make ws URL from |pages= interwiki link; link portion L becomes tooltip label&lt;br /&gt;
		if ws_url then&lt;br /&gt;
			pages = external_link (ws_url, ws_label .. '&amp;amp;nbsp;', 'ws link in pages');	-- space char after label to move icon away from in-source text; TODO: a better way to do this?&lt;br /&gt;
			pages = utilities.substitute (cfg.presentation['interwiki-icon'], {cfg.presentation['class-wikisource'], L, pages});&lt;br /&gt;
			coins_pages = ws_label;&lt;br /&gt;
		end&lt;br /&gt;
	elseif utilities.is_set (at) then&lt;br /&gt;
		ws_url, ws_label, L = wikisource_url_make (at);							-- make ws URL from |at= interwiki link; link portion L becomes tooltip label&lt;br /&gt;
		if ws_url then&lt;br /&gt;
			at = external_link (ws_url, ws_label .. '&amp;amp;nbsp;', 'ws link in at');	-- space char after label to move icon away from in-source text; TODO: a better way to do this?&lt;br /&gt;
			at = utilities.substitute (cfg.presentation['interwiki-icon'], {cfg.presentation['class-wikisource'], L, at});&lt;br /&gt;
			coins_pages = ws_label;&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	return page, pages, at, coins_pages;&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[=[-------------------------&amp;lt; A R C H I V E _ U R L _ C H E C K &amp;gt;--------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Check archive.org URLs to make sure they at least look like they are pointing at valid archives and not to the &lt;br /&gt;
save snapshot URL or to calendar pages.  When the archive URL is 'https://web.archive.org/save/' (or http://...)&lt;br /&gt;
archive.org saves a snapshot of the target page in the URL.  That is something that Wikipedia should not allow&lt;br /&gt;
unwitting readers to do.&lt;br /&gt;
&lt;br /&gt;
When the archive.org URL does not have a complete timestamp, archive.org chooses a snapshot according to its own&lt;br /&gt;
algorithm or provides a calendar 'search' result.  [[WP:ELNO]] discourages links to search results.&lt;br /&gt;
&lt;br /&gt;
This function looks at the value assigned to |archive-url= and returns empty strings for |archive-url= and&lt;br /&gt;
|archive-date= and an error message when:&lt;br /&gt;
	|archive-url= holds an archive.org save command URL&lt;br /&gt;
	|archive-url= is an archive.org URL that does not have a complete timestamp (YYYYMMDDhhmmss 14 digits) in the&lt;br /&gt;
		correct place&lt;br /&gt;
otherwise returns |archive-url= and |archive-date=&lt;br /&gt;
&lt;br /&gt;
There are two mostly compatible archive.org URLs:&lt;br /&gt;
	//web.archive.org/&amp;lt;timestamp&amp;gt;...		-- the old form&lt;br /&gt;
	//web.archive.org/web/&amp;lt;timestamp&amp;gt;...	-- the new form&lt;br /&gt;
&lt;br /&gt;
The old form does not support or map to the new form when it contains a display flag.  There are four identified flags&lt;br /&gt;
('id_', 'js_', 'cs_', 'im_') but since archive.org ignores others following the same form (two letters and an underscore)&lt;br /&gt;
we don't check for these specific flags but we do check the form.&lt;br /&gt;
&lt;br /&gt;
This function supports a preview mode.  When the article is rendered in preview mode, this function may return a modified&lt;br /&gt;
archive URL:&lt;br /&gt;
	for save command errors, return undated wildcard (/*/)&lt;br /&gt;
	for timestamp errors when the timestamp has a wildcard, return the URL unmodified&lt;br /&gt;
	for timestamp errors when the timestamp does not have a wildcard, return with timestamp limited to six digits plus wildcard (/yyyymm*/)&lt;br /&gt;
&lt;br /&gt;
]=]&lt;br /&gt;
&lt;br /&gt;
local function archive_url_check (url, date)&lt;br /&gt;
	local err_msg = '';															-- start with the error message empty&lt;br /&gt;
	local path, timestamp, flag;												-- portions of the archive.org URL&lt;br /&gt;
	&lt;br /&gt;
	if (not url:match('//web%.archive%.org/')) and (not url:match('//liveweb%.archive%.org/')) then		-- also deprecated liveweb Wayback machine URL&lt;br /&gt;
		return url, date;														-- not an archive.org archive, return ArchiveURL and ArchiveDate&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if url:match('//web%.archive%.org/save/') then								-- if a save command URL, we don't want to allow saving of the target page &lt;br /&gt;
		err_msg = cfg.err_msg_supl.save;&lt;br /&gt;
		url = url:gsub ('(//web%.archive%.org)/save/', '%1/*/', 1);				-- for preview mode: modify ArchiveURL&lt;br /&gt;
	elseif url:match('//liveweb%.archive%.org/') then&lt;br /&gt;
		err_msg = cfg.err_msg_supl.liveweb;&lt;br /&gt;
	else&lt;br /&gt;
		path, timestamp, flag = url:match('//web%.archive%.org/([^%d]*)(%d+)([^/]*)/');	-- split out some of the URL parts for evaluation&lt;br /&gt;
		&lt;br /&gt;
		if not utilities.is_set (timestamp) or 14 ~= timestamp:len() then		-- path and flag optional, must have 14-digit timestamp here&lt;br /&gt;
			err_msg = cfg.err_msg_supl.timestamp;&lt;br /&gt;
			if '*' ~= flag then&lt;br /&gt;
				url=url:gsub ('(//web%.archive%.org/[^%d]*%d?%d?%d?%d?%d?%d?)[^/]*', '%1*', 1)	-- for preview, modify ts to be yearmo* max (0-6 digits plus splat)&lt;br /&gt;
			end&lt;br /&gt;
		elseif utilities.is_set (path) and 'web/' ~= path then					-- older archive URLs do not have the extra 'web/' path element&lt;br /&gt;
			err_msg = cfg.err_msg_supl.path;&lt;br /&gt;
		elseif utilities.is_set (flag) and not utilities.is_set (path) then		-- flag not allowed with the old form URL (without the 'web/' path element)&lt;br /&gt;
			err_msg = cfg.err_msg_supl.flag;&lt;br /&gt;
		elseif utilities.is_set (flag) and not flag:match ('%a%a_') then		-- flag if present must be two alpha characters and underscore (requires 'web/' path element)&lt;br /&gt;
			err_msg = cfg.err_msg_supl.flag;&lt;br /&gt;
		else&lt;br /&gt;
			return url, date;													-- return ArchiveURL and ArchiveDate&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
																				-- if here, something not right so&lt;br /&gt;
	table.insert( z.message_tail, { utilities.set_message ( 'err_archive_url', {err_msg}, true ) } );	-- add error message and&lt;br /&gt;
	if utilities.is_set (Frame:preprocess('{{REVISIONID}}')) then&lt;br /&gt;
		return '', '';															-- return empty strings for ArchiveURL and ArchiveDate&lt;br /&gt;
	else&lt;br /&gt;
		return url, date;														-- preview mode so return ArchiveURL and ArchiveDate&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; P L A C E _ C H E C K &amp;gt;--------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
check |place=, |publication-place=, |location= to see if these params include digits.  This function added because&lt;br /&gt;
many editors misuse location to specify the in-source location (|page(s)= and |at= are supposed to do that)&lt;br /&gt;
&lt;br /&gt;
returns the original parameter value without modification; added maint cat when parameter value contains digits&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function place_check (param_val)&lt;br /&gt;
	if not utilities.is_set (param_val) then									-- parameter empty or omitted&lt;br /&gt;
		return param_val;														-- return that empty state&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	if mw.ustring.find (param_val, '%d') then									-- not empty, are there digits in the parameter value&lt;br /&gt;
		utilities.set_message ('maint_location');								-- yep, add maint cat&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	return param_val;															-- and done&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; I S _ G E N E R I C _ T I T L E &amp;gt;----------------------------------------------&lt;br /&gt;
&lt;br /&gt;
compares |title= value against list of known generic title patterns.  Returns true when pattern matches; nil else&lt;br /&gt;
&lt;br /&gt;
the k/v pairs in 'generic_titles' each contain two tables, one for English and one for another 'local' language&lt;br /&gt;
Each of those tables contain another table that holds the string or pattern (whole title or title fragment) in&lt;br /&gt;
index [1].  index [2] is a Boolean that tells string.find() or mw.ustring.find() to do plain-text search (true)&lt;br /&gt;
or a pattern search (false).  The intent of all this complexity is to make these searches as fast as possible so&lt;br /&gt;
that we don't run out of processing time on very large articles.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function is_generic_title (title)&lt;br /&gt;
	title = mw.ustring.lower(title);											-- switch title to lower case&lt;br /&gt;
	for _, generic_title in ipairs (cfg.special_case_translation['generic_titles']) do	--spin through the list of known generic title fragments&lt;br /&gt;
		if title:find (generic_title['en'][1], 1, generic_title['en'][2]) then&lt;br /&gt;
			return true;														-- found English generic title so done&lt;br /&gt;
		elseif generic_title['local'] then										-- to keep work load down, generic_title['local'] should be nil except when there is a local version of the generic title&lt;br /&gt;
			if mw.ustring.find (title, generic_title['local'][1], 1, generic_title['local'][2]) then	-- mw.ustring() because might not be Latin script&lt;br /&gt;
				return true;													-- found local generic title so done&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; I S _ A R C H I V E D _ C O P Y &amp;gt;----------------------------------------------&lt;br /&gt;
&lt;br /&gt;
compares |title= to 'Archived copy' (place holder added by bots that can't find proper title); if matches, return true; nil else&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function is_archived_copy (title)&lt;br /&gt;
	title = mw.ustring.lower(title);											-- switch title to lower case&lt;br /&gt;
	if title:find (cfg.special_case_translation.archived_copy.en) then			-- if title is 'Archived copy'&lt;br /&gt;
		return true;&lt;br /&gt;
	elseif cfg.special_case_translation.archived_copy['local'] then&lt;br /&gt;
		if mw.ustring.find (title, cfg.special_case_translation.archived_copy['local']) then	-- mw.ustring() because might not be Latin script&lt;br /&gt;
			return true;&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; C I T A T I O N 0 &amp;gt;------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
This is the main function doing the majority of the citation formatting.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function citation0( config, args)&lt;br /&gt;
	--[[ &lt;br /&gt;
	Load Input Parameters&lt;br /&gt;
	The argument_wrapper facilitates the mapping of multiple aliases to single internal variable.&lt;br /&gt;
	]]&lt;br /&gt;
	local A = argument_wrapper ( args );&lt;br /&gt;
	local i &lt;br /&gt;
&lt;br /&gt;
	-- Pick out the relevant fields from the arguments.  Different citation templates&lt;br /&gt;
	-- define different field names for the same underlying things.	&lt;br /&gt;
&lt;br /&gt;
	local Mode = is_valid_parameter_value (A['Mode'], A:ORIGIN('Mode'), cfg.keywords_lists['mode'], '');&lt;br /&gt;
&lt;br /&gt;
	local author_etal;&lt;br /&gt;
	local a	= {};																-- authors list from |lastn= / |firstn= pairs or |vauthors=&lt;br /&gt;
	local Authors;&lt;br /&gt;
&lt;br /&gt;
	local NameListStyle = is_valid_parameter_value (A['NameListStyle'], A:ORIGIN('NameListStyle'), cfg.keywords_lists['name-list-style'], '');&lt;br /&gt;
	local Collaboration = A['Collaboration'];&lt;br /&gt;
&lt;br /&gt;
	do																			-- to limit scope of selected&lt;br /&gt;
		local selected = select_author_editor_source (A['Vauthors'], A['Authors'], args, 'AuthorList');&lt;br /&gt;
		if 1 == selected then&lt;br /&gt;
			a, author_etal = extract_names (args, 'AuthorList');				-- fetch author list from |authorn= / |lastn= / |firstn=, |author-linkn=, and |author-maskn=&lt;br /&gt;
		elseif 2 == selected then&lt;br /&gt;
			NameListStyle = 'vanc';											-- override whatever |name-list-style= might be&lt;br /&gt;
			a, author_etal = parse_vauthors_veditors (args, args.vauthors, 'AuthorList');	-- fetch author list from |vauthors=, |author-linkn=, and |author-maskn=&lt;br /&gt;
		elseif 3 == selected then&lt;br /&gt;
			Authors = A['Authors'];												-- use content of |authors=&lt;br /&gt;
			if 'authors' == A:ORIGIN('Authors') then							-- but add a maint cat if the parameter is |authors=&lt;br /&gt;
				utilities.set_message ('maint_authors');						-- because use of this parameter is discouraged; what to do about the aliases is a TODO:&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
		if utilities.is_set (Collaboration) then&lt;br /&gt;
			author_etal = true;													-- so that |display-authors=etal not required&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local Others = A['Others'];&lt;br /&gt;
&lt;br /&gt;
	local editor_etal;&lt;br /&gt;
	local e	= {};																-- editors list from |editor-lastn= / |editor-firstn= pairs or |veditors=&lt;br /&gt;
	local Editors;&lt;br /&gt;
&lt;br /&gt;
	do																			-- to limit scope of selected&lt;br /&gt;
		local selected = select_author_editor_source (A['Veditors'], A['Editors'], args, 'EditorList');&lt;br /&gt;
		if 1 == selected then&lt;br /&gt;
			e, editor_etal = extract_names (args, 'EditorList');				-- fetch editor list from |editorn= / |editor-lastn= / |editor-firstn=, |editor-linkn=, and |editor-maskn=&lt;br /&gt;
		elseif 2 == selected then&lt;br /&gt;
			NameListStyle = 'vanc';											-- override whatever |name-list-style= might be&lt;br /&gt;
			e, editor_etal = parse_vauthors_veditors (args, args.veditors, 'EditorList');	-- fetch editor list from |veditors=, |editor-linkn=, and |editor-maskn=&lt;br /&gt;
		elseif 3 == selected then&lt;br /&gt;
			Editors = A['Editors'];												-- use content of |editors=&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local translator_etal;&lt;br /&gt;
	local t = {};																-- translators list from |translator-lastn= / translator-firstn= pairs&lt;br /&gt;
	local Translators;															-- assembled translators name list&lt;br /&gt;
	t = extract_names (args, 'TranslatorList');									-- fetch translator list from |translatorn= / |translator-lastn=, -firstn=, -linkn=, -maskn=&lt;br /&gt;
&lt;br /&gt;
	local interviewer_etal;&lt;br /&gt;
	local interviewers_list = {};												&lt;br /&gt;
	local Interviewers;															-- used later&lt;br /&gt;
	interviewers_list = extract_names (args, 'InterviewerList');				-- process preferred interviewers parameters&lt;br /&gt;
&lt;br /&gt;
	local contributor_etal;&lt;br /&gt;
	local c = {};																-- contributors list from |contributor-lastn= / contributor-firstn= pairs&lt;br /&gt;
	local Contributors;															-- assembled contributors name list&lt;br /&gt;
&lt;br /&gt;
	local Chapter = A['Chapter'];												-- done here so that we have access to |contribution= from |chapter= aliases&lt;br /&gt;
	local Chapter_origin = A:ORIGIN ('Chapter');&lt;br /&gt;
	local Contribution;															-- because contribution is required for contributor(s)&lt;br /&gt;
		if 'contribution' == A:ORIGIN ('Chapter') then&lt;br /&gt;
			Contribution = A['Chapter'];										-- get the name of the contribution&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
	if utilities.in_array (config.CitationClass, {&amp;quot;book&amp;quot;, &amp;quot;citation&amp;quot;}) and not utilities.is_set (A['Periodical']) then	-- |contributor= and |contribution= only supported in book cites&lt;br /&gt;
		c = extract_names (args, 'ContributorList');							-- fetch contributor list from |contributorn= / |contributor-lastn=, -firstn=, -linkn=, -maskn=&lt;br /&gt;
		&lt;br /&gt;
		if 0 &amp;lt; #c then&lt;br /&gt;
			if not utilities.is_set (Contribution) then							-- |contributor= requires |contribution=&lt;br /&gt;
				table.insert( z.message_tail, { utilities.set_message ( 'err_contributor_missing_required_param', 'contribution')});	-- add missing contribution error message&lt;br /&gt;
				c = {};															-- blank the contributors' table; it is used as a flag later&lt;br /&gt;
			end&lt;br /&gt;
			if 0 == #a then														-- |contributor= requires |author=&lt;br /&gt;
				table.insert( z.message_tail, { utilities.set_message ( 'err_contributor_missing_required_param', 'author')});	-- add missing author error message&lt;br /&gt;
				c = {};															-- blank the contributors' table; it is used as a flag later&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	else																		-- if not a book cite&lt;br /&gt;
		if utilities.select_one (args, cfg.aliases['ContributorList-Last'], 'err_redundant_parameters', 1 ) then	-- are there contributor name list parameters?&lt;br /&gt;
			table.insert( z.message_tail, { utilities.set_message ( 'err_contributor_ignored')});	-- add contributor ignored error message&lt;br /&gt;
		end&lt;br /&gt;
		Contribution = nil;														-- unset&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if utilities.is_set (Others) then&lt;br /&gt;
		if 0 == #a and 0 == #e then												-- add maint cat when |others= has value and used without |author=, |editor=&lt;br /&gt;
			utilities.set_message ('maint_others');&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local Year = A['Year'];&lt;br /&gt;
	local PublicationDate = A['PublicationDate'];&lt;br /&gt;
	local OrigDate = A['OrigDate'];&lt;br /&gt;
	local Date = A['Date'];&lt;br /&gt;
	local LayDate = A['LayDate'];&lt;br /&gt;
	------------------------------------------------- Get title data&lt;br /&gt;
	local Title = A['Title'];&lt;br /&gt;
	local ScriptTitle = A['ScriptTitle'];&lt;br /&gt;
	local BookTitle = A['BookTitle'];&lt;br /&gt;
	local Conference = A['Conference'];&lt;br /&gt;
	local TransTitle = A['TransTitle'];&lt;br /&gt;
	local TransTitle_origin = A:ORIGIN ('TransTitle');&lt;br /&gt;
	local TitleNote = A['TitleNote'];&lt;br /&gt;
	local TitleLink = A['TitleLink'];&lt;br /&gt;
&lt;br /&gt;
	local auto_select = ''; -- default is auto&lt;br /&gt;
	local accept_link;&lt;br /&gt;
	TitleLink, accept_link = utilities.has_accept_as_written(TitleLink, true); -- test for accept-this-as-written markup&lt;br /&gt;
	if (not accept_link) and utilities.in_array (TitleLink, {'none', 'pmc', 'doi'}) then -- check for special keywords&lt;br /&gt;
		auto_select = TitleLink; -- remember selection for later&lt;br /&gt;
		TitleLink = ''; -- treat as if |title-link= would have been empty&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	TitleLink = link_title_ok (TitleLink, A:ORIGIN ('TitleLink'), Title, 'title');	-- check for wiki-markup in |title-link= or wiki-markup in |title= when |title-link= is set&lt;br /&gt;
&lt;br /&gt;
	local Section = '';															-- {{cite map}} only; preset to empty string for concatenation if not used&lt;br /&gt;
		if 'map' == config.CitationClass and 'section' == A:ORIGIN ('Chapter') then&lt;br /&gt;
			Section = A['Chapter'];												-- get |section= from |chapter= alias list; |chapter= and the other aliases not supported in {{cite map}}&lt;br /&gt;
			Chapter = '';														-- unset for now; will be reset later from |map= if present&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
	local ScriptChapter = A['ScriptChapter'];&lt;br /&gt;
	local ScriptChapter_origin = A:ORIGIN ('ScriptChapter');&lt;br /&gt;
	local ChapterLink -- = A['ChapterLink'];									-- deprecated as a parameter but still used internally by cite episode&lt;br /&gt;
	local TransChapter = A['TransChapter'];&lt;br /&gt;
	local TransChapter_origin = A:ORIGIN ('TransChapter');&lt;br /&gt;
	local TitleType = A['TitleType'];&lt;br /&gt;
	local Degree = A['Degree'];&lt;br /&gt;
	local Docket = A['Docket'];&lt;br /&gt;
	local ArchiveFormat = A['ArchiveFormat'];&lt;br /&gt;
&lt;br /&gt;
	local ArchiveDate;&lt;br /&gt;
	local ArchiveURL;&lt;br /&gt;
&lt;br /&gt;
	ArchiveURL, ArchiveDate = archive_url_check (A['ArchiveURL'], A['ArchiveDate'])&lt;br /&gt;
	&lt;br /&gt;
	local UrlStatus = is_valid_parameter_value (A['UrlStatus'], A:ORIGIN('UrlStatus'), cfg.keywords_lists['url-status'], '');&lt;br /&gt;
&lt;br /&gt;
	local URL = A['URL']&lt;br /&gt;
	local URL_origin = A:ORIGIN('URL');											-- get name of parameter that holds URL&lt;br /&gt;
	local ChapterURL = A['ChapterURL'];&lt;br /&gt;
	local ChapterURL_origin = A:ORIGIN('ChapterURL');							-- get name of parameter that holds ChapterURL&lt;br /&gt;
	local ConferenceFormat = A['ConferenceFormat'];&lt;br /&gt;
	local ConferenceURL = A['ConferenceURL'];&lt;br /&gt;
	local ConferenceURL_origin = A:ORIGIN('ConferenceURL');						-- get name of parameter that holds ConferenceURL&lt;br /&gt;
&lt;br /&gt;
	local Periodical = A['Periodical'];&lt;br /&gt;
	local Periodical_origin = '';&lt;br /&gt;
	if utilities.is_set (Periodical) then&lt;br /&gt;
		Periodical_origin = A:ORIGIN('Periodical');								-- get the name of the periodical parameter&lt;br /&gt;
		local i;&lt;br /&gt;
		Periodical, i = utilities.strip_apostrophe_markup (Periodical);			-- strip apostrophe markup so that metadata isn't contaminated &lt;br /&gt;
		if i then																-- non-zero when markup was stripped so emit an error message&lt;br /&gt;
			table.insert( z.message_tail, {utilities.set_message ('err_apostrophe_markup', {Periodical_origin}, true)});&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if 'mailinglist' == config.CitationClass then								-- special case for {{cite mailing list}}&lt;br /&gt;
		if utilities.is_set (Periodical) and utilities.is_set (A ['MailingList']) then	-- both set emit an error&lt;br /&gt;
			table.insert( z.message_tail, {utilities.set_message ('err_redundant_parameters', {utilities.wrap_style ('parameter', Periodical_origin) .. ' and ' .. utilities.wrap_style ('parameter', 'mailinglist')}, true )});&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
		Periodical = A ['MailingList'];											-- error or no, set Periodical to |mailinglist= value because this template is {{cite mailing list}}&lt;br /&gt;
		Periodical_origin = A:ORIGIN('MailingList');&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local ScriptPeriodical = A['ScriptPeriodical'];&lt;br /&gt;
	local ScriptPeriodical_origin = A:ORIGIN('ScriptPeriodical');&lt;br /&gt;
&lt;br /&gt;
	-- web and news not tested for now because of &lt;br /&gt;
	-- Wikipedia:Administrators%27_noticeboard#Is_there_a_semi-automated_tool_that_could_fix_these_annoying_&amp;quot;Cite_Web&amp;quot;_errors?&lt;br /&gt;
	if not (utilities.is_set (Periodical) or utilities.is_set (ScriptPeriodical)) then	-- 'periodical' templates require periodical parameter&lt;br /&gt;
	--	local p = {['journal'] = 'journal', ['magazine'] = 'magazine', ['news'] = 'newspaper', ['web'] = 'website'};	-- for error message&lt;br /&gt;
		local p = {['journal'] = 'journal', ['magazine'] = 'magazine'};			-- for error message&lt;br /&gt;
		if p[config.CitationClass]  then&lt;br /&gt;
			table.insert( z.message_tail, {utilities.set_message ('err_missing_periodical', {config.CitationClass, p[config.CitationClass]}, true)});&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local TransPeriodical =  A['TransPeriodical'];&lt;br /&gt;
	local TransPeriodical_origin =  A:ORIGIN ('TransPeriodical');&lt;br /&gt;
&lt;br /&gt;
	local Series = A['Series'];&lt;br /&gt;
	&lt;br /&gt;
	local Volume;&lt;br /&gt;
	local Issue;&lt;br /&gt;
	local Page;&lt;br /&gt;
	local Pages;&lt;br /&gt;
	local At;&lt;br /&gt;
&lt;br /&gt;
	if 'citation' == config.CitationClass then&lt;br /&gt;
		if utilities.is_set (Periodical) then&lt;br /&gt;
			if not utilities.in_array (Periodical_origin, {'website', 'mailinglist'}) then	-- {{citation}} does not render volume for these 'periodicals'&lt;br /&gt;
				Volume = A['Volume'];											-- but does for all other 'periodicals'&lt;br /&gt;
			end&lt;br /&gt;
		elseif utilities.is_set (ScriptPeriodical) then&lt;br /&gt;
			if 'script-website' ~= ScriptPeriodical_origin then					-- {{citation}} does not render volume for |script-website=&lt;br /&gt;
				Volume = A['Volume'];											-- but does for all other 'periodicals'&lt;br /&gt;
			end&lt;br /&gt;
		else&lt;br /&gt;
			Volume = A['Volume'];												-- and does for non-'periodical' cites&lt;br /&gt;
		end&lt;br /&gt;
	elseif utilities.in_array (config.CitationClass, cfg.templates_using_volume) then	-- render |volume= for cs1 according to the configuration settings&lt;br /&gt;
		Volume = A['Volume'];&lt;br /&gt;
	end	&lt;br /&gt;
&lt;br /&gt;
	if 'citation' == config.CitationClass then&lt;br /&gt;
		if utilities.is_set (Periodical) and utilities.in_array (Periodical_origin, {'journal', 'magazine', 'newspaper', 'periodical', 'work'}) or	-- {{citation}} renders issue for these 'periodicals'&lt;br /&gt;
			utilities.is_set (ScriptPeriodical) and utilities.in_array (ScriptPeriodical_origin, {'script-journal', 'script-magazine', 'script-newspaper', 'script-periodical', 'script-work'}) then -- and these 'script-periodicals'&lt;br /&gt;
				Issue = hyphen_to_dash (A['Issue']);&lt;br /&gt;
		end&lt;br /&gt;
	elseif utilities.in_array (config.CitationClass, cfg.templates_using_issue) then	-- conference &amp;amp; map books do not support issue; {{citation}} listed here because included in settings table&lt;br /&gt;
		if not (utilities.in_array (config.CitationClass, {'conference', 'map', 'citation'}) and not (utilities.is_set (Periodical) or utilities.is_set (ScriptPeriodical))) then&lt;br /&gt;
			Issue = hyphen_to_dash (A['Issue']);&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local Position = '';&lt;br /&gt;
	if not utilities.in_array (config.CitationClass, cfg.templates_not_using_page) then&lt;br /&gt;
		Page = A['Page'];&lt;br /&gt;
		Pages = hyphen_to_dash (A['Pages']);	&lt;br /&gt;
		At = A['At'];&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local Edition = A['Edition'];&lt;br /&gt;
	local PublicationPlace = place_check (A['PublicationPlace'], A:ORIGIN('PublicationPlace'));&lt;br /&gt;
	local Place = place_check (A['Place'], A:ORIGIN('Place'));&lt;br /&gt;
	&lt;br /&gt;
	local PublisherName = A['PublisherName'];&lt;br /&gt;
	local PublisherName_origin = A:ORIGIN('PublisherName');&lt;br /&gt;
	if utilities.is_set (PublisherName) then&lt;br /&gt;
		local i = 0;&lt;br /&gt;
		PublisherName, i = utilities.strip_apostrophe_markup (PublisherName);	-- strip apostrophe markup so that metadata isn't contaminated; publisher is never italicized&lt;br /&gt;
		if i then																-- non-zero when markup was stripped so emit an error message&lt;br /&gt;
			table.insert( z.message_tail, {utilities.set_message ('err_apostrophe_markup', {PublisherName_origin}, true)});&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local Newsgroup = A['Newsgroup'];											-- TODO: strip apostrophe markup?&lt;br /&gt;
	local Newsgroup_origin = A:ORIGIN('Newsgroup');	&lt;br /&gt;
&lt;br /&gt;
	if 'newsgroup' == config.CitationClass then&lt;br /&gt;
		if utilities.is_set (PublisherName) then								-- general use parameter |publisher= not allowed in cite newsgroup&lt;br /&gt;
			local error_text, error_state = utilities.set_message ('err_parameter_ignored', {PublisherName_origin}, true);&lt;br /&gt;
			if utilities.is_set (error_text) then&lt;br /&gt;
				table.insert( z.message_tail, {error_text, error_state} );&lt;br /&gt;
			end				&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
		PublisherName = nil;													-- ensure that this parameter is unset for the time being; will be used again after COinS&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local UrlAccess = is_valid_parameter_value (A['UrlAccess'], A:ORIGIN('UrlAccess'), cfg.keywords_lists['url-access'], nil);&lt;br /&gt;
		if not utilities.is_set (URL) and utilities.is_set (UrlAccess) then&lt;br /&gt;
			UrlAccess = nil;&lt;br /&gt;
			table.insert( z.message_tail, { utilities.set_message ( 'err_param_access_requires_param', {'url'}, true ) } );&lt;br /&gt;
		end&lt;br /&gt;
		&lt;br /&gt;
	local ChapterUrlAccess = is_valid_parameter_value (A['ChapterUrlAccess'], A:ORIGIN('ChapterUrlAccess'), cfg.keywords_lists['url-access'], nil);&lt;br /&gt;
	if not utilities.is_set (ChapterURL) and utilities.is_set (ChapterUrlAccess) then&lt;br /&gt;
		ChapterUrlAccess = nil;&lt;br /&gt;
		table.insert( z.message_tail, { utilities.set_message ( 'err_param_access_requires_param', {A:ORIGIN('ChapterUrlAccess'):gsub ('%-access', '')}, true ) } );&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local MapUrlAccess = is_valid_parameter_value (A['MapUrlAccess'], A:ORIGIN('MapUrlAccess'), cfg.keywords_lists['url-access'], nil);&lt;br /&gt;
	if not utilities.is_set (A['MapURL']) and utilities.is_set (MapUrlAccess) then&lt;br /&gt;
		MapUrlAccess = nil;&lt;br /&gt;
		table.insert( z.message_tail, { utilities.set_message ( 'err_param_access_requires_param', {'map-url'}, true ) } );&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local Via = A['Via'];&lt;br /&gt;
	local AccessDate = A['AccessDate'];&lt;br /&gt;
	local Agency = A['Agency'];&lt;br /&gt;
&lt;br /&gt;
	local Language = A['Language'];&lt;br /&gt;
	local Format = A['Format'];&lt;br /&gt;
	local ChapterFormat = A['ChapterFormat'];&lt;br /&gt;
	local DoiBroken = A['DoiBroken'];&lt;br /&gt;
	local ID = A['ID'];&lt;br /&gt;
	local ASINTLD = A['ASINTLD'];&lt;br /&gt;
	local IgnoreISBN = is_valid_parameter_value (A['IgnoreISBN'], A:ORIGIN('IgnoreISBN'), cfg.keywords_lists['yes_true_y'], nil);&lt;br /&gt;
	local Embargo = A['Embargo'];&lt;br /&gt;
	local Class = A['Class'];													-- arxiv class identifier&lt;br /&gt;
&lt;br /&gt;
	local Quote = A['Quote'];&lt;br /&gt;
	local QuotePage = A['QuotePage'];&lt;br /&gt;
	local QuotePages = A['QuotePages'];&lt;br /&gt;
	local ScriptQuote = A['ScriptQuote'];&lt;br /&gt;
	local TransQuote = A['TransQuote'];&lt;br /&gt;
&lt;br /&gt;
	local LayFormat = A['LayFormat'];&lt;br /&gt;
	local LayURL = A['LayURL'];&lt;br /&gt;
	local LaySource = A['LaySource'];&lt;br /&gt;
	local Transcript = A['Transcript'];&lt;br /&gt;
	local TranscriptFormat = A['TranscriptFormat'];&lt;br /&gt;
	local TranscriptURL = A['TranscriptURL'] &lt;br /&gt;
	local TranscriptURL_origin = A:ORIGIN('TranscriptURL');						-- get name of parameter that holds TranscriptURL&lt;br /&gt;
&lt;br /&gt;
	local LastAuthorAmp = is_valid_parameter_value (A['LastAuthorAmp'], A:ORIGIN('LastAuthorAmp'), cfg.keywords_lists['yes_true_y'], nil);&lt;br /&gt;
&lt;br /&gt;
	local no_tracking_cats = is_valid_parameter_value (A['NoTracking'], A:ORIGIN('NoTracking'), cfg.keywords_lists['yes_true_y'], nil);&lt;br /&gt;
	if 'nocat' == A:ORIGIN('NoTracking') then				&lt;br /&gt;
		utilities.set_message ('maint_nocat');									-- this one so that we get the message; see main categorization at end of citation0()&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	--local variables that are not cs1 parameters&lt;br /&gt;
	local use_lowercase;														-- controls capitalization of certain static text&lt;br /&gt;
	local this_page = mw.title.getCurrentTitle();								-- also used for COinS and for language&lt;br /&gt;
	local anchor_year;															-- used in the CITEREF identifier&lt;br /&gt;
	local COinS_date = {};														-- holds date info extracted from |date= for the COinS metadata by Module:Date verification&lt;br /&gt;
&lt;br /&gt;
	local DF = is_valid_parameter_value (A['DF'], A:ORIGIN('DF'), cfg.keywords_lists['df'], '');&lt;br /&gt;
	if not utilities.is_set (DF) then&lt;br /&gt;
		DF = cfg.global_df;														-- local |df= if present overrides global df set by {{use xxx date}} template&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local sepc;																	-- separator between citation elements for CS1 a period, for CS2, a comma&lt;br /&gt;
	local PostScript;&lt;br /&gt;
	local Ref = A['Ref'];&lt;br /&gt;
	if 'harv' == Ref then&lt;br /&gt;
		utilities.set_message ('maint_ref_harv');								-- add maint cat to identify templates that have this now-extraneous param value&lt;br /&gt;
	elseif not utilities.is_set (Ref) then&lt;br /&gt;
		Ref = 'harv';															-- set as default when not set externally&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	sepc, PostScript, Ref = set_style (Mode:lower(), A['PostScript'], Ref, config.CitationClass);&lt;br /&gt;
	use_lowercase = ( sepc == ',' ); 											-- used to control capitalization for certain static text&lt;br /&gt;
&lt;br /&gt;
	-- check this page to see if it is in one of the namespaces that cs1 is not supposed to add to the error categories&lt;br /&gt;
	if not utilities.is_set (no_tracking_cats) then								-- ignore if we are already not going to categorize this page&lt;br /&gt;
		if utilities.in_array (this_page.nsText, cfg.uncategorized_namespaces) then&lt;br /&gt;
			no_tracking_cats = &amp;quot;true&amp;quot;;											-- set no_tracking_cats&lt;br /&gt;
		end&lt;br /&gt;
		for _, v in ipairs (cfg.uncategorized_subpages) do						-- cycle through page name patterns&lt;br /&gt;
			if this_page.text:match (v) then									-- test page name against each pattern&lt;br /&gt;
				no_tracking_cats = &amp;quot;true&amp;quot;;										-- set no_tracking_cats&lt;br /&gt;
				break;															-- bail out if one is found&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
																				-- check for extra |page=, |pages= or |at= parameters. (also sheet and sheets while we're at it)&lt;br /&gt;
	utilities.select_one (args, {'page', 'p', 'pp', 'pages', 'at', 'sheet', 'sheets'}, 'err_redundant_parameters');	-- this is a dummy call simply to get the error message and category&lt;br /&gt;
&lt;br /&gt;
	local coins_pages;&lt;br /&gt;
	&lt;br /&gt;
	Page, Pages, At, coins_pages = insource_loc_get (Page, Pages, At);&lt;br /&gt;
&lt;br /&gt;
	local NoPP = is_valid_parameter_value (A['NoPP'], A:ORIGIN('NoPP'), cfg.keywords_lists['yes_true_y'], nil);&lt;br /&gt;
&lt;br /&gt;
	if utilities.is_set (PublicationPlace) and utilities.is_set (Place) then	-- both |publication-place= and |place= (|location=) allowed if different&lt;br /&gt;
		utilities.add_prop_cat ('location test');								-- add property cat to evaluate how often PublicationPlace and Place are used together&lt;br /&gt;
		if PublicationPlace == Place then&lt;br /&gt;
			Place = '';															-- unset; don't need both if they are the same&lt;br /&gt;
		end&lt;br /&gt;
	elseif not utilities.is_set (PublicationPlace) and utilities.is_set (Place) then	-- when only |place= (|location=) is set ...&lt;br /&gt;
		PublicationPlace = Place;												-- promote |place= (|location=) to |publication-place&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if PublicationPlace == Place then Place = ''; end							-- don't need both if they are the same&lt;br /&gt;
	&lt;br /&gt;
	--[[&lt;br /&gt;
	Parameter remapping for cite encyclopedia:&lt;br /&gt;
	When the citation has these parameters:&lt;br /&gt;
		|encyclopedia= and |title= then map |title= to |article= and |encyclopedia= to |title=&lt;br /&gt;
		|encyclopedia= and |article= then map |encyclopedia= to |title=&lt;br /&gt;
&lt;br /&gt;
		|trans-title= maps to |trans-chapter= when |title= is re-mapped&lt;br /&gt;
		|url= maps to |chapter-url= when |title= is remapped&lt;br /&gt;
	&lt;br /&gt;
	All other combinations of |encyclopedia=, |title=, and |article= are not modified&lt;br /&gt;
	&lt;br /&gt;
	]]&lt;br /&gt;
&lt;br /&gt;
	local Encyclopedia = A['Encyclopedia'];										-- used as a flag by this module and by ~/COinS&lt;br /&gt;
&lt;br /&gt;
	if utilities.is_set (Encyclopedia) then										-- emit error message when Encyclopedia set but template is other than {{cite encyclopedia}} or {{citation}}&lt;br /&gt;
		if 'encyclopaedia' ~= config.CitationClass and 'citation' ~= config.CitationClass then&lt;br /&gt;
			table.insert (z.message_tail, {utilities.set_message ('err_parameter_ignored', {A:ORIGIN ('Encyclopedia')}, true)});&lt;br /&gt;
			Encyclopedia = nil;													-- unset because not supported by this template&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if ('encyclopaedia' == config.CitationClass) or ('citation' == config.CitationClass and utilities.is_set (Encyclopedia)) then&lt;br /&gt;
		if utilities.is_set (Periodical) and utilities.is_set (Encyclopedia) then	-- when both set emit an error&lt;br /&gt;
			table.insert (z.message_tail, {utilities.set_message ('err_redundant_parameters', {utilities.wrap_style ('parameter', A:ORIGIN ('Encyclopedia')) .. ' and ' .. utilities.wrap_style ('parameter', Periodical_origin)}, true )});&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
		if utilities.is_set (Encyclopedia) then&lt;br /&gt;
			Periodical = Encyclopedia;											-- error or no, set Periodical to Encyclopedia; allow periodical without encyclopedia&lt;br /&gt;
			Periodical_origin = A:ORIGIN ('Encyclopedia');&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
		if utilities.is_set (Periodical) then									-- Periodical is set when |encyclopedia= is set&lt;br /&gt;
			if utilities.is_set (Title) or utilities.is_set (ScriptTitle) then&lt;br /&gt;
				if not utilities.is_set (Chapter) then&lt;br /&gt;
					Chapter = Title;											-- |encyclopedia= and |title= are set so map |title= to |article= and |encyclopedia= to |title=&lt;br /&gt;
					ScriptChapter = ScriptTitle;&lt;br /&gt;
					ScriptChapter_origin = A:ORIGIN('ScriptTitle')&lt;br /&gt;
					TransChapter = TransTitle;&lt;br /&gt;
					ChapterURL = URL;&lt;br /&gt;
					ChapterURL_origin = A:ORIGIN('URL')&lt;br /&gt;
&lt;br /&gt;
					ChapterUrlAccess = UrlAccess;&lt;br /&gt;
&lt;br /&gt;
					if not utilities.is_set (ChapterURL) and utilities.is_set (TitleLink) then&lt;br /&gt;
						Chapter = utilities.make_wikilink (TitleLink, Chapter);&lt;br /&gt;
					end&lt;br /&gt;
					Title = Periodical;&lt;br /&gt;
					ChapterFormat = Format;&lt;br /&gt;
					Periodical = '';											-- redundant so unset&lt;br /&gt;
					TransTitle = '';&lt;br /&gt;
					URL = '';&lt;br /&gt;
					Format = '';&lt;br /&gt;
					TitleLink = '';&lt;br /&gt;
					ScriptTitle = '';&lt;br /&gt;
				end&lt;br /&gt;
			elseif utilities.is_set (Chapter) then								-- |title= not set&lt;br /&gt;
				Title = Periodical;												-- |encyclopedia= set and |article= set so map |encyclopedia= to |title=&lt;br /&gt;
				Periodical = '';												-- redundant so unset&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- special case for cite techreport.&lt;br /&gt;
	if (config.CitationClass == &amp;quot;techreport&amp;quot;) then								-- special case for cite techreport&lt;br /&gt;
		if utilities.is_set (A['Number']) then									-- cite techreport uses 'number', which other citations alias to 'issue'&lt;br /&gt;
			if not utilities.is_set (ID) then									-- can we use ID for the &amp;quot;number&amp;quot;?&lt;br /&gt;
				ID = A['Number'];												-- yes, use it&lt;br /&gt;
			else																-- ID has a value so emit error message&lt;br /&gt;
				table.insert( z.message_tail, { utilities.set_message ('err_redundant_parameters', {utilities.wrap_style ('parameter', 'id') .. ' and ' .. utilities.wrap_style ('parameter', 'number')}, true )});&lt;br /&gt;
			end&lt;br /&gt;
		end	&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Account for the oddity that is {{cite conference}}, before generation of COinS data.&lt;br /&gt;
	if 'conference' == config.CitationClass then&lt;br /&gt;
		if utilities.is_set (BookTitle) then&lt;br /&gt;
			Chapter = Title;&lt;br /&gt;
			Chapter_origin = 'title';&lt;br /&gt;
	--		ChapterLink = TitleLink;											-- |chapter-link= is deprecated&lt;br /&gt;
			ChapterURL = URL;&lt;br /&gt;
			ChapterUrlAccess = UrlAccess;&lt;br /&gt;
			ChapterURL_origin = URL_origin;&lt;br /&gt;
			URL_origin = '';&lt;br /&gt;
			ChapterFormat = Format;&lt;br /&gt;
			TransChapter = TransTitle;&lt;br /&gt;
			TransChapter_origin = TransTitle_origin;&lt;br /&gt;
			Title = BookTitle;&lt;br /&gt;
			Format = '';&lt;br /&gt;
	--		TitleLink = '';&lt;br /&gt;
			TransTitle = '';&lt;br /&gt;
			URL = '';&lt;br /&gt;
		end&lt;br /&gt;
	elseif 'speech' ~= config.CitationClass then&lt;br /&gt;
		Conference = '';														-- not cite conference or cite speech so make sure this is empty string&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- cite map oddities&lt;br /&gt;
	local Cartography = &amp;quot;&amp;quot;;&lt;br /&gt;
	local Scale = &amp;quot;&amp;quot;;&lt;br /&gt;
	local Sheet = A['Sheet'] or '';&lt;br /&gt;
	local Sheets = A['Sheets'] or '';&lt;br /&gt;
	if config.CitationClass == &amp;quot;map&amp;quot; then&lt;br /&gt;
		if utilities.is_set (Chapter) then&lt;br /&gt;
			table.insert( z.message_tail, { utilities.set_message ( 'err_redundant_parameters', {utilities.wrap_style ('parameter', 'map') .. ' and ' .. utilities.wrap_style ('parameter', Chapter_origin)}, true ) } );	-- add error message&lt;br /&gt;
		end&lt;br /&gt;
		Chapter = A['Map'];&lt;br /&gt;
		Chapter_origin = A:ORIGIN('Map');&lt;br /&gt;
		ChapterURL = A['MapURL'];&lt;br /&gt;
		ChapterURL_origin = A:ORIGIN('MapURL');&lt;br /&gt;
		TransChapter = A['TransMap'];&lt;br /&gt;
		ScriptChapter = A['ScriptMap']&lt;br /&gt;
		ScriptChapter_origin = A:ORIGIN('ScriptMap')&lt;br /&gt;
&lt;br /&gt;
		ChapterUrlAccess = MapUrlAccess;&lt;br /&gt;
		ChapterFormat = A['MapFormat'];&lt;br /&gt;
&lt;br /&gt;
		Cartography = A['Cartography'];&lt;br /&gt;
		if utilities.is_set ( Cartography ) then&lt;br /&gt;
			Cartography = sepc .. &amp;quot; &amp;quot; .. wrap_msg ('cartography', Cartography, use_lowercase);&lt;br /&gt;
		end		&lt;br /&gt;
		Scale = A['Scale'];&lt;br /&gt;
		if utilities.is_set ( Scale ) then&lt;br /&gt;
			Scale = sepc .. &amp;quot; &amp;quot; .. Scale;&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Account for the oddities that are {{cite episode}} and {{cite serial}}, before generation of COinS data.&lt;br /&gt;
	if 'episode' == config.CitationClass or 'serial' == config.CitationClass then&lt;br /&gt;
		local SeriesLink = A['SeriesLink'];&lt;br /&gt;
&lt;br /&gt;
		SeriesLink = link_title_ok (SeriesLink, A:ORIGIN ('SeriesLink'), Series, 'series');	-- check for wiki-markup in |series-link= or wiki-markup in |series= when |series-link= is set&lt;br /&gt;
&lt;br /&gt;
		local Network = A['Network'];&lt;br /&gt;
		local Station = A['Station'];&lt;br /&gt;
		local s, n = {}, {};&lt;br /&gt;
																				-- do common parameters first&lt;br /&gt;
		if utilities.is_set (Network) then table.insert(n, Network); end&lt;br /&gt;
		if utilities.is_set (Station) then table.insert(n, Station); end&lt;br /&gt;
		ID = table.concat(n, sepc .. ' ');&lt;br /&gt;
		&lt;br /&gt;
		if 'episode' == config.CitationClass then								-- handle the oddities that are strictly {{cite episode}}&lt;br /&gt;
			local Season = A['Season'];&lt;br /&gt;
			local SeriesNumber = A['SeriesNumber'];&lt;br /&gt;
&lt;br /&gt;
			if utilities.is_set (Season) and utilities.is_set (SeriesNumber) then	-- these are mutually exclusive so if both are set&lt;br /&gt;
				table.insert( z.message_tail, { utilities.set_message ( 'err_redundant_parameters', {utilities.wrap_style ('parameter', 'season') .. ' and ' .. utilities.wrap_style ('parameter', 'seriesno')}, true ) } );		-- add error message&lt;br /&gt;
				SeriesNumber = '';												-- unset; prefer |season= over |seriesno=&lt;br /&gt;
			end&lt;br /&gt;
																				-- assemble a table of parts concatenated later into Series&lt;br /&gt;
			if utilities.is_set (Season) then table.insert(s, wrap_msg ('season', Season, use_lowercase)); end&lt;br /&gt;
			if utilities.is_set (SeriesNumber) then table.insert(s, wrap_msg ('seriesnum', SeriesNumber, use_lowercase)); end&lt;br /&gt;
			if utilities.is_set (Issue) then table.insert(s, wrap_msg ('episode', Issue, use_lowercase)); end&lt;br /&gt;
			Issue = '';															-- unset because this is not a unique parameter&lt;br /&gt;
	&lt;br /&gt;
			Chapter = Title;													-- promote title parameters to chapter&lt;br /&gt;
			ScriptChapter = ScriptTitle;&lt;br /&gt;
			ScriptChapter_origin = A:ORIGIN('ScriptTitle');&lt;br /&gt;
			ChapterLink = TitleLink;											-- alias |episode-link=&lt;br /&gt;
			TransChapter = TransTitle;&lt;br /&gt;
			ChapterURL = URL;&lt;br /&gt;
			ChapterUrlAccess = UrlAccess;&lt;br /&gt;
			ChapterURL_origin = A:ORIGIN('URL');&lt;br /&gt;
			&lt;br /&gt;
			Title = Series;														-- promote series to title&lt;br /&gt;
			TitleLink = SeriesLink;&lt;br /&gt;
			Series = table.concat(s, sepc .. ' ');								-- this is concatenation of season, seriesno, episode number&lt;br /&gt;
&lt;br /&gt;
			if utilities.is_set (ChapterLink) and not utilities.is_set (ChapterURL) then	-- link but not URL&lt;br /&gt;
				Chapter = utilities.make_wikilink (ChapterLink, Chapter);&lt;br /&gt;
			elseif utilities.is_set (ChapterLink) and utilities.is_set (ChapterURL) then	-- if both are set, URL links episode;&lt;br /&gt;
				Series = utilities.make_wikilink (ChapterLink, Series);&lt;br /&gt;
			end&lt;br /&gt;
			URL = '';															-- unset&lt;br /&gt;
			TransTitle = '';&lt;br /&gt;
			ScriptTitle = '';&lt;br /&gt;
			&lt;br /&gt;
		else																	-- now oddities that are cite serial&lt;br /&gt;
			Issue = '';															-- unset because this parameter no longer supported by the citation/core version of cite serial&lt;br /&gt;
			Chapter = A['Episode'];												-- TODO: make |episode= available to cite episode someday?&lt;br /&gt;
			if utilities.is_set (Series) and utilities.is_set (SeriesLink) then&lt;br /&gt;
				Series = utilities.make_wikilink (SeriesLink, Series);&lt;br /&gt;
			end&lt;br /&gt;
			Series = utilities.wrap_style ('italic-title', Series);				-- series is italicized&lt;br /&gt;
		end	&lt;br /&gt;
	end&lt;br /&gt;
	-- end of {{cite episode}} stuff&lt;br /&gt;
&lt;br /&gt;
	-- handle type parameter for those CS1 citations that have default values&lt;br /&gt;
	if utilities.in_array (config.CitationClass, {&amp;quot;AV-media-notes&amp;quot;, &amp;quot;interview&amp;quot;, &amp;quot;mailinglist&amp;quot;, &amp;quot;map&amp;quot;, &amp;quot;podcast&amp;quot;, &amp;quot;pressrelease&amp;quot;, &amp;quot;report&amp;quot;, &amp;quot;techreport&amp;quot;, &amp;quot;thesis&amp;quot;}) then&lt;br /&gt;
		TitleType = set_titletype (config.CitationClass, TitleType);&lt;br /&gt;
		if utilities.is_set (Degree) and &amp;quot;Thesis&amp;quot; == TitleType then				-- special case for cite thesis&lt;br /&gt;
			TitleType = Degree .. ' ' .. cfg.title_types ['thesis']:lower();&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if utilities.is_set (TitleType) then										-- if type parameter is specified&lt;br /&gt;
		TitleType = utilities.substitute ( cfg.messages['type'], TitleType);	-- display it in parentheses&lt;br /&gt;
	-- TODO: Hack on TitleType to fix bunched parentheses problem&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- legacy: promote PublicationDate to Date if neither Date nor Year are set.&lt;br /&gt;
 	local Date_origin;															-- to hold the name of parameter promoted to Date; required for date error messaging&lt;br /&gt;
&lt;br /&gt;
	if not utilities.is_set (Date) then&lt;br /&gt;
		Date = Year;															-- promote Year to Date&lt;br /&gt;
		Year = nil;																-- make nil so Year as empty string isn't used for CITEREF&lt;br /&gt;
		if not utilities.is_set (Date) and utilities.is_set (PublicationDate) then	-- use PublicationDate when |date= and |year= are not set&lt;br /&gt;
			Date = PublicationDate;												-- promote PublicationDate to Date&lt;br /&gt;
			PublicationDate = '';												-- unset, no longer needed&lt;br /&gt;
			Date_origin = A:ORIGIN('PublicationDate');							-- save the name of the promoted parameter&lt;br /&gt;
		else&lt;br /&gt;
			Date_origin = A:ORIGIN('Year');										-- save the name of the promoted parameter&lt;br /&gt;
		end&lt;br /&gt;
	else&lt;br /&gt;
		Date_origin = A:ORIGIN('Date');											-- not a promotion; name required for error messaging&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if PublicationDate == Date then PublicationDate = ''; end					-- if PublicationDate is same as Date, don't display in rendered citation&lt;br /&gt;
&lt;br /&gt;
	--[[&lt;br /&gt;
	Go test all of the date-holding parameters for valid MOS:DATE format and make sure that dates are real dates. This must be done before we do COinS because here is where&lt;br /&gt;
	we get the date used in the metadata.&lt;br /&gt;
	&lt;br /&gt;
	Date validation supporting code is in Module:Citation/CS1/Date_validation&lt;br /&gt;
	]]&lt;br /&gt;
	do	-- create defined block to contain local variables error_message, date_parameters_list, mismatch&lt;br /&gt;
		local error_message = '';&lt;br /&gt;
																				-- AirDate has been promoted to Date so not necessary to check it&lt;br /&gt;
		local date_parameters_list = {&lt;br /&gt;
			['access-date'] = {val = AccessDate, name = A:ORIGIN ('AccessDate')},&lt;br /&gt;
			['archive-date'] = {val = ArchiveDate, name = A:ORIGIN ('ArchiveDate')},&lt;br /&gt;
			['date'] = {val = Date, name = Date_origin},&lt;br /&gt;
			['doi-broken-date'] = {val = DoiBroken, name = A:ORIGIN ('DoiBroken')},&lt;br /&gt;
			['pmc-embargo-date'] = {val = Embargo, name = A:ORIGIN ('Embargo')},&lt;br /&gt;
			['lay-date'] = {val = LayDate, name = A:ORIGIN ('LayDate')},&lt;br /&gt;
			['publication-date'] = {val = PublicationDate, name = A:ORIGIN ('PublicationDate')},&lt;br /&gt;
			['year'] = {val = Year, name = A:ORIGIN ('Year')},&lt;br /&gt;
			};&lt;br /&gt;
&lt;br /&gt;
		local error_list = {};&lt;br /&gt;
		anchor_year, Embargo = validation.dates(date_parameters_list, COinS_date, error_list);&lt;br /&gt;
&lt;br /&gt;
-- start temporary Julian / Gregorian calendar uncertainty categorization&lt;br /&gt;
		if COinS_date.inter_cal_cat then&lt;br /&gt;
			utilities.add_prop_cat ('jul_greg_uncertainty');&lt;br /&gt;
		end&lt;br /&gt;
-- end temporary Julian / Gregorian calendar uncertainty categorization&lt;br /&gt;
&lt;br /&gt;
		if utilities.is_set (Year) and utilities.is_set (Date) then				-- both |date= and |year= not normally needed; &lt;br /&gt;
			local mismatch = validation.year_date_check (Year, Date);&lt;br /&gt;
			if 0 == mismatch then												-- |year= does not match a year-value in |date=&lt;br /&gt;
				table.insert (error_list, '&amp;lt;code class=&amp;quot;cs1-code&amp;quot;&amp;gt;&amp;amp;#124;year= / &amp;amp;#124;date= mismatch&amp;lt;/code&amp;gt;');&lt;br /&gt;
			elseif 1 == mismatch then											-- |year= matches year-value in |date=&lt;br /&gt;
				utilities.set_message ('maint_date_year');						-- add a maint cat&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
		&lt;br /&gt;
		if 0 == #error_list then												-- error free dates only; 0 when error_list is empty&lt;br /&gt;
			local modified = false;												-- flag&lt;br /&gt;
			&lt;br /&gt;
			if utilities.is_set (DF) then										-- if we need to reformat dates&lt;br /&gt;
				modified = validation.reformat_dates (date_parameters_list, DF);	-- reformat to DF format, use long month names if appropriate&lt;br /&gt;
			end&lt;br /&gt;
&lt;br /&gt;
			if true == validation.date_hyphen_to_dash (date_parameters_list) then	-- convert hyphens to dashes where appropriate&lt;br /&gt;
				modified = true;&lt;br /&gt;
				utilities.set_message ('maint_date_format');					-- hyphens were converted so add maint category&lt;br /&gt;
			end&lt;br /&gt;
			&lt;br /&gt;
	-- for those wikis that can and want to have English date names translated to the local language,&lt;br /&gt;
	-- uncomment the next three lines.  Not supported by en.wiki (for obvious reasons)&lt;br /&gt;
	-- set validation.date_name_xlate() second argument to true to translate English digits to local digits (will translate ymd dates)&lt;br /&gt;
	--		if validation.date_name_xlate (date_parameters_list, false) then&lt;br /&gt;
	--			modified = true;&lt;br /&gt;
	--		end&lt;br /&gt;
&lt;br /&gt;
			if modified then													-- if the date_parameters_list values were modified&lt;br /&gt;
				AccessDate = date_parameters_list['access-date'].val;			-- overwrite date holding parameters with modified values&lt;br /&gt;
				ArchiveDate = date_parameters_list['archive-date'].val;&lt;br /&gt;
				Date = date_parameters_list['date'].val;&lt;br /&gt;
				DoiBroken = date_parameters_list['doi-broken-date'].val;&lt;br /&gt;
				LayDate = date_parameters_list['lay-date'].val;&lt;br /&gt;
				PublicationDate = date_parameters_list['publication-date'].val;&lt;br /&gt;
			end&lt;br /&gt;
		else&lt;br /&gt;
			table.insert (z.message_tail, {utilities.set_message ('err_bad_date', {utilities.make_sep_list (#error_list, error_list)}, true)});	-- add this error message&lt;br /&gt;
		end&lt;br /&gt;
	end	-- end of do&lt;br /&gt;
&lt;br /&gt;
	local ID_list_coins = identifiers.extract_ids (args);						-- gets identifiers and their values from args; this list used for COinS and source for build_id_list()&lt;br /&gt;
		if utilities.is_set (DoiBroken) and not ID_list_coins['DOI'] then&lt;br /&gt;
			table.insert (z.message_tail, {utilities.set_message ('err_doibroken_missing_doi', A:ORIGIN('DoiBroken'))});&lt;br /&gt;
		end&lt;br /&gt;
	local ID_access_levels = identifiers.extract_id_access_levels (args, ID_list_coins);&lt;br /&gt;
	local ID_list = identifiers.build_id_list (ID_list_coins, {IdAccessLevels = ID_access_levels, DoiBroken = DoiBroken, ASINTLD = ASINTLD, IgnoreISBN = IgnoreISBN, Embargo = Embargo, Class = Class});	-- render identifiers&lt;br /&gt;
	&lt;br /&gt;
	-- Account for the oddities that are {{cite arxiv}}, {{cite biorxiv}}, {{cite citeseerx}}, {{cite ssrn}}, before generation of COinS data.&lt;br /&gt;
	if utilities.in_array (config.CitationClass, whitelist.preprint_template_list) then&lt;br /&gt;
		if not utilities.is_set (ID_list_coins[config.CitationClass:upper()]) then 	-- |arxiv= or |eprint= required for cite arxiv; |biorxiv= &amp;amp; |citeseerx= required for their templates&lt;br /&gt;
			table.insert (z.message_tail, {utilities.set_message ('err_' .. config.CitationClass .. '_missing', {}, true)});	-- add error message&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
		Periodical = ({['arxiv'] = 'arXiv', ['biorxiv'] = 'bioRxiv', ['citeseerx'] = 'CiteSeerX', ['ssrn'] = 'Social Science Research Network'})[config.CitationClass];&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Link the title of the work if no |url= was provided, but we have a |pmc= or a |doi= with |doi-access=free&lt;br /&gt;
&lt;br /&gt;
	if config.CitationClass == &amp;quot;journal&amp;quot; and not utilities.is_set (URL) and not utilities.is_set (TitleLink) and not utilities.in_array (cfg.keywords_xlate[Title], {'off', 'none'}) then -- TODO: remove 'none' once existing citations have been switched to 'off', so 'none' can be used as token for &amp;quot;no title&amp;quot; instead&lt;br /&gt;
    		if 'none' ~= cfg.keywords_xlate[auto_select] then -- if auto-linking not disabled&lt;br /&gt;
 	 		if identifiers.auto_link_urls[auto_select] then -- manual selection&lt;br /&gt;
		 		URL = identifiers.auto_link_urls[auto_select]; -- set URL to be the same as identifier's external link&lt;br /&gt;
 				URL_origin = cfg.id_handlers[auto_select:upper()].parameters[1]; -- set URL_origin to parameter name for use in error message if citation is missing a |title=&lt;br /&gt;
			elseif identifiers.auto_link_urls['pmc'] then -- auto-select PMC&lt;br /&gt;
				URL = identifiers.auto_link_urls['pmc']; -- set URL to be the same as the PMC external link if not embargoed&lt;br /&gt;
				URL_origin = cfg.id_handlers['PMC'].parameters[1]; -- set URL_origin to parameter name for use in error message if citation is missing a |title=&lt;br /&gt;
			elseif identifiers.auto_link_urls['doi'] then -- auto-select DOI&lt;br /&gt;
				URL = identifiers.auto_link_urls['doi'];&lt;br /&gt;
				URL_origin = cfg.id_handlers['DOI'].parameters[1];&lt;br /&gt;
			end&lt;br /&gt;
 	 	end&lt;br /&gt;
&lt;br /&gt;
		if utilities.is_set (URL) and utilities.is_set (AccessDate) then		-- access date requires |url=; identifier-created URL is not |url=&lt;br /&gt;
			table.insert( z.message_tail, { utilities.set_message ( 'err_accessdate_missing_url', {}, true ) } );	-- add an error message&lt;br /&gt;
			AccessDate = '';													-- unset&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- At this point fields may be nil if they weren't specified in the template use.  We can use that fact.&lt;br /&gt;
	-- Test if citation has no title&lt;br /&gt;
	if	not utilities.is_set (Title) and not utilities.is_set (TransTitle) and not utilities.is_set (ScriptTitle) then	-- has special case for cite episode&lt;br /&gt;
		table.insert( z.message_tail, { utilities.set_message ( 'err_citation_missing_title', {'episode' == config.CitationClass and 'series' or 'title'}, true ) } );&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if utilities.in_array (cfg.keywords_xlate[Title], {'off', 'none'}) and&lt;br /&gt;
			utilities.in_array (config.CitationClass, {'journal', 'citation'}) and&lt;br /&gt;
			(utilities.is_set (Periodical) or utilities.is_set (ScriptPeriodical)) and&lt;br /&gt;
			('journal' == Periodical_origin or 'script-journal' == ScriptPeriodical_origin) then	-- special case for journal cites&lt;br /&gt;
				Title = '';														-- set title to empty string&lt;br /&gt;
				utilities.set_message ('maint_untitled');						-- add maint cat&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	check_for_url ({															-- add error message when any of these parameters hold a URL&lt;br /&gt;
		['title']=Title,&lt;br /&gt;
		[A:ORIGIN('Chapter')]=Chapter,&lt;br /&gt;
		[Periodical_origin] = Periodical,&lt;br /&gt;
		[PublisherName_origin] = PublisherName&lt;br /&gt;
		});&lt;br /&gt;
&lt;br /&gt;
	-- COinS metadata (see &amp;lt;http://ocoins.info/&amp;gt;) for automated parsing of citation information.&lt;br /&gt;
	-- handle the oddity that is cite encyclopedia and {{citation |encyclopedia=something}}. Here we presume that&lt;br /&gt;
	-- when Periodical, Title, and Chapter are all set, then Periodical is the book (encyclopedia) title, Title&lt;br /&gt;
	-- is the article title, and Chapter is a section within the article.  So, we remap &lt;br /&gt;
	&lt;br /&gt;
	local coins_chapter = Chapter;												-- default assuming that remapping not required&lt;br /&gt;
	local coins_title = Title;													-- et tu&lt;br /&gt;
	if 'encyclopaedia' == config.CitationClass or ('citation' == config.CitationClass and utilities.is_set (Encyclopedia)) then&lt;br /&gt;
		if utilities.is_set (Chapter) and utilities.is_set (Title) and utilities.is_set (Periodical) then		-- if all are used then&lt;br /&gt;
			coins_chapter = Title;												-- remap&lt;br /&gt;
			coins_title = Periodical;&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	local coins_author = a;														-- default for coins rft.au &lt;br /&gt;
	if 0 &amp;lt; #c then																-- but if contributor list&lt;br /&gt;
		coins_author = c;														-- use that instead&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- this is the function call to COinS()&lt;br /&gt;
	local OCinSoutput = metadata.COinS({&lt;br /&gt;
		['Periodical'] = utilities.strip_apostrophe_markup (Periodical),		-- no markup in the metadata&lt;br /&gt;
		['Encyclopedia'] = Encyclopedia,										-- just a flag; content ignored by ~/COinS&lt;br /&gt;
		['Chapter'] = metadata.make_coins_title (coins_chapter, ScriptChapter),	-- Chapter and ScriptChapter stripped of bold / italic wiki-markup&lt;br /&gt;
		['Degree'] = Degree;													-- cite thesis only&lt;br /&gt;
		['Title'] = metadata.make_coins_title (coins_title, ScriptTitle),		-- Title and ScriptTitle stripped of bold / italic wiki-markup&lt;br /&gt;
		['PublicationPlace'] = PublicationPlace,&lt;br /&gt;
		['Date'] = COinS_date.rftdate,											-- COinS_date has correctly formatted date if Date is valid;&lt;br /&gt;
		['Season'] = COinS_date.rftssn,&lt;br /&gt;
		['Quarter'] = COinS_date.rftquarter,&lt;br /&gt;
		['Chron'] =  COinS_date.rftchron or (not COinS_date.rftdate and Date) or '',	-- chron but if not set and invalid date format use Date; keep this last bit?&lt;br /&gt;
		['Series'] = Series,&lt;br /&gt;
		['Volume'] = Volume,&lt;br /&gt;
		['Issue'] = Issue,&lt;br /&gt;
		['Pages'] = coins_pages or metadata.get_coins_pages (first_set ({Sheet, Sheets, Page, Pages, At}, 5)),	-- pages stripped of external links&lt;br /&gt;
		['Edition'] = Edition,&lt;br /&gt;
		['PublisherName'] = PublisherName or Newsgroup,							-- any apostrophe markup already removed from PublisherName&lt;br /&gt;
		['URL'] = first_set ({ChapterURL, URL}, 2),&lt;br /&gt;
		['Authors'] = coins_author,&lt;br /&gt;
		['ID_list'] = ID_list_coins,&lt;br /&gt;
		['RawPage'] = this_page.prefixedText,&lt;br /&gt;
	}, config.CitationClass);&lt;br /&gt;
&lt;br /&gt;
	-- Account for the oddities that are {{cite arxiv}}, {{cite biorxiv}}, {{cite citeseerx}}, and {{cite ssrn}} AFTER generation of COinS data.&lt;br /&gt;
	if utilities.in_array (config.CitationClass, whitelist.preprint_template_list) then	-- we have set rft.jtitle in COinS to arXiv, bioRxiv, CiteSeerX, or ssrn now unset so it isn't displayed&lt;br /&gt;
		Periodical = '';														-- periodical not allowed in these templates; if article has been published, use cite journal&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- special case for cite newsgroup.  Do this after COinS because we are modifying Publishername to include some static text&lt;br /&gt;
	if 'newsgroup' == config.CitationClass and utilities.is_set (Newsgroup) then&lt;br /&gt;
		PublisherName = utilities.substitute (cfg.messages['newsgroup'], external_link( 'news:' .. Newsgroup, Newsgroup, Newsgroup_origin, nil ));&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Now perform various field substitutions.&lt;br /&gt;
	-- We also add leading spaces and surrounding markup and punctuation to the&lt;br /&gt;
	-- various parts of the citation, but only when they are non-nil.&lt;br /&gt;
	local EditorCount;															-- used only for choosing {ed.) or (eds.) annotation at end of editor name-list&lt;br /&gt;
	do&lt;br /&gt;
		local last_first_list;&lt;br /&gt;
		local control = { &lt;br /&gt;
			format = NameListStyle,											-- empty string or 'vanc'&lt;br /&gt;
			maximum = nil,														-- as if display-authors or display-editors not set&lt;br /&gt;
			lastauthoramp = LastAuthorAmp,&lt;br /&gt;
			mode = Mode&lt;br /&gt;
		};&lt;br /&gt;
&lt;br /&gt;
		do																		-- do editor name list first because the now unsupported coauthors used to modify control table&lt;br /&gt;
			control.maximum , editor_etal = get_display_names (A['DisplayEditors'], #e, 'editors', editor_etal);&lt;br /&gt;
			last_first_list, EditorCount = list_people(control, e, editor_etal);&lt;br /&gt;
&lt;br /&gt;
			if utilities.is_set (Editors) then&lt;br /&gt;
				Editors, editor_etal = name_has_etal (Editors, editor_etal, false, 'editors');	-- find and remove variations on et al.&lt;br /&gt;
				if editor_etal then&lt;br /&gt;
					Editors = Editors .. ' ' .. cfg.messages['et al'];			-- add et al. to editors parameter beause |display-editors=etal&lt;br /&gt;
				end&lt;br /&gt;
				EditorCount = 2;												-- we don't know but assume |editors= is multiple names; spoof to display (eds.) annotation&lt;br /&gt;
			else&lt;br /&gt;
				Editors = last_first_list;										-- either an author name list or an empty string&lt;br /&gt;
			end&lt;br /&gt;
&lt;br /&gt;
			if 1 == EditorCount and (true == editor_etal or 1 &amp;lt; #e) then		-- only one editor displayed but includes etal then &lt;br /&gt;
				EditorCount = 2;												-- spoof to display (eds.) annotation&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
		do																		-- now do interviewers&lt;br /&gt;
			control.maximum , interviewer_etal = get_display_names (A['DisplayInterviewers'], #interviewers_list, 'interviewers', interviewer_etal);&lt;br /&gt;
			Interviewers = list_people (control, interviewers_list, interviewer_etal);&lt;br /&gt;
		end&lt;br /&gt;
		do																		-- now do translators&lt;br /&gt;
			control.maximum , translator_etal = get_display_names (A['DisplayTranslators'], #t, 'translators', translator_etal);&lt;br /&gt;
			Translators = list_people (control, t, translator_etal);&lt;br /&gt;
		end&lt;br /&gt;
		do																		-- now do contributors&lt;br /&gt;
			control.maximum , contributor_etal = get_display_names (A['DisplayContributors'], #c, 'contributors', contributor_etal);&lt;br /&gt;
			Contributors = list_people (control, c, contributor_etal);&lt;br /&gt;
		end&lt;br /&gt;
		do																		-- now do authors&lt;br /&gt;
			control.maximum , author_etal = get_display_names (A['DisplayAuthors'], #a, 'authors', author_etal);&lt;br /&gt;
&lt;br /&gt;
			last_first_list = list_people(control, a, author_etal);&lt;br /&gt;
&lt;br /&gt;
			if utilities.is_set (Authors) then&lt;br /&gt;
				Authors, author_etal = name_has_etal (Authors, author_etal, false, 'authors');	-- find and remove variations on et al.&lt;br /&gt;
				if author_etal then&lt;br /&gt;
					Authors = Authors .. ' ' .. cfg.messages['et al'];			-- add et al. to authors parameter&lt;br /&gt;
				end&lt;br /&gt;
			else&lt;br /&gt;
				Authors = last_first_list;										-- either an author name list or an empty string&lt;br /&gt;
			end&lt;br /&gt;
		end																		-- end of do&lt;br /&gt;
	&lt;br /&gt;
		if utilities.is_set (Authors) and utilities.is_set (Collaboration) then&lt;br /&gt;
			Authors = Authors .. ' (' .. Collaboration .. ')';					-- add collaboration after et al.&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- apply |[xx-]format= styling; at the end, these parameters hold correctly styled format annotation,&lt;br /&gt;
	-- an error message if the associated URL is not set, or an empty string for concatenation&lt;br /&gt;
	ArchiveFormat = style_format (ArchiveFormat, ArchiveURL, 'archive-format', 'archive-url');&lt;br /&gt;
	ConferenceFormat = style_format (ConferenceFormat, ConferenceURL, 'conference-format', 'conference-url');&lt;br /&gt;
	Format = style_format (Format, URL, 'format', 'url');&lt;br /&gt;
	LayFormat = style_format (LayFormat, LayURL, 'lay-format', 'lay-url');&lt;br /&gt;
	TranscriptFormat = style_format (TranscriptFormat, TranscriptURL, 'transcript-format', 'transcripturl');&lt;br /&gt;
&lt;br /&gt;
	-- special case for chapter format so no error message or cat when chapter not supported&lt;br /&gt;
	if not (utilities.in_array (config.CitationClass, {'web', 'news', 'journal', 'magazine', 'pressrelease', 'podcast', 'newsgroup', 'arxiv', 'biorxiv', 'citeseerx', 'ssrn'}) or&lt;br /&gt;
		('citation' == config.CitationClass and (utilities.is_set (Periodical) or utilities.is_set (ScriptPeriodical)) and not utilities.is_set (Encyclopedia))) then&lt;br /&gt;
			ChapterFormat = style_format (ChapterFormat, ChapterURL, 'chapter-format', 'chapter-url');&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if not utilities.is_set (URL) then&lt;br /&gt;
		if utilities.in_array (config.CitationClass, {&amp;quot;web&amp;quot;, &amp;quot;podcast&amp;quot;, &amp;quot;mailinglist&amp;quot;}) or		-- |url= required for cite web, cite podcast, and cite mailinglist&lt;br /&gt;
			('citation' == config.CitationClass and ('website' == Periodical_origin or 'script-website' == ScriptPeriodical_origin)) then	-- and required for {{citation}} with |website= or |script-website=&lt;br /&gt;
				table.insert( z.message_tail, { utilities.set_message ( 'err_cite_web_url', {}, true ) } );&lt;br /&gt;
		end&lt;br /&gt;
		&lt;br /&gt;
		-- do we have |accessdate= without either |url= or |chapter-url=?&lt;br /&gt;
		if utilities.is_set (AccessDate) and not utilities.is_set (ChapterURL) then		-- ChapterURL may be set when URL is not set;&lt;br /&gt;
			table.insert( z.message_tail, { utilities.set_message ( 'err_accessdate_missing_url', {}, true ) } );&lt;br /&gt;
			AccessDate = '';&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local OriginalURL, OriginalURL_origin, OriginalFormat, OriginalAccess;&lt;br /&gt;
	UrlStatus = UrlStatus:lower();												-- used later when assembling archived text&lt;br /&gt;
	if utilities.is_set ( ArchiveURL ) then&lt;br /&gt;
		if utilities.is_set (ChapterURL) then 									-- if chapter-url= is set apply archive url to it&lt;br /&gt;
			OriginalURL = ChapterURL;											-- save copy of source chapter's url for archive text&lt;br /&gt;
			OriginalURL_origin = ChapterURL_origin;								-- name of |chapter-url= parameter for error messages&lt;br /&gt;
			OriginalFormat = ChapterFormat;										-- and original |chapter-format=&lt;br /&gt;
&lt;br /&gt;
			if 'live' ~= UrlStatus then&lt;br /&gt;
				ChapterURL = ArchiveURL											-- swap-in the archive's URL&lt;br /&gt;
				ChapterURL_origin = A:ORIGIN('ArchiveURL')						-- name of |archive-url= parameter for error messages&lt;br /&gt;
				ChapterFormat = ArchiveFormat or '';							-- swap in archive's format&lt;br /&gt;
				ChapterUrlAccess = nil;											-- restricted access levels do not make sense for archived URLs&lt;br /&gt;
			end&lt;br /&gt;
		elseif utilities.is_set (URL) then&lt;br /&gt;
			OriginalURL = URL;													-- save copy of original source URL&lt;br /&gt;
			OriginalURL_origin = URL_origin;									-- name of URL parameter for error messages&lt;br /&gt;
			OriginalFormat = Format; 											-- and original |format=&lt;br /&gt;
			OriginalAccess = UrlAccess;&lt;br /&gt;
&lt;br /&gt;
			if 'live' ~= UrlStatus then											-- if URL set then |archive-url= applies to it&lt;br /&gt;
				URL = ArchiveURL												-- swap-in the archive's URL&lt;br /&gt;
				URL_origin = A:ORIGIN('ArchiveURL')								-- name of archive URL parameter for error messages&lt;br /&gt;
				Format = ArchiveFormat or '';									-- swap in archive's format&lt;br /&gt;
				UrlAccess = nil;												-- restricted access levels do not make sense for archived URLs&lt;br /&gt;
			end&lt;br /&gt;
 		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if utilities.in_array (config.CitationClass, {'web', 'news', 'journal', 'magazine', 'pressrelease', 'podcast', 'newsgroup', 'arxiv', 'biorxiv', 'citeseerx', 'ssrn'}) or	-- if any of the 'periodical' cites except encyclopedia&lt;br /&gt;
		('citation' == config.CitationClass and (utilities.is_set (Periodical) or utilities.is_set (ScriptPeriodical)) and not utilities.is_set (Encyclopedia)) then&lt;br /&gt;
			local chap_param;&lt;br /&gt;
			if utilities.is_set (Chapter) then									-- get a parameter name from one of these chapter related meta-parameters&lt;br /&gt;
				chap_param = A:ORIGIN ('Chapter')&lt;br /&gt;
			elseif utilities.is_set (TransChapter) then&lt;br /&gt;
				chap_param = A:ORIGIN ('TransChapter')&lt;br /&gt;
			elseif utilities.is_set (ChapterURL) then&lt;br /&gt;
				chap_param = A:ORIGIN ('ChapterURL')&lt;br /&gt;
			elseif utilities.is_set (ScriptChapter) then&lt;br /&gt;
				chap_param = ScriptChapter_origin;&lt;br /&gt;
			else utilities.is_set (ChapterFormat)&lt;br /&gt;
				chap_param = A:ORIGIN ('ChapterFormat')&lt;br /&gt;
			end&lt;br /&gt;
&lt;br /&gt;
			if utilities.is_set (chap_param) then								-- if we found one&lt;br /&gt;
				table.insert( z.message_tail, { utilities.set_message ( 'err_chapter_ignored', {chap_param}, true ) } );	-- add error message&lt;br /&gt;
				Chapter = '';													-- and set them to empty string to be safe with concatenation&lt;br /&gt;
				TransChapter = '';&lt;br /&gt;
				ChapterURL = '';&lt;br /&gt;
				ScriptChapter = '';&lt;br /&gt;
				ChapterFormat = '';&lt;br /&gt;
			end&lt;br /&gt;
	else																		-- otherwise, format chapter / article title&lt;br /&gt;
		local no_quotes = false;												-- default assume that we will be quoting the chapter parameter value&lt;br /&gt;
		if utilities.is_set (Contribution) and 0 &amp;lt; #c then						-- if this is a contribution with contributor(s)&lt;br /&gt;
			if utilities.in_array (Contribution:lower(), cfg.keywords_lists.contribution) then	-- and a generic contribution title&lt;br /&gt;
				no_quotes = true;												-- then render it unquoted&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
		Chapter = format_chapter_title (ScriptChapter, ScriptChapter_origin, Chapter, Chapter_origin, TransChapter, TransChapter_origin, ChapterURL, ChapterURL_origin, no_quotes, ChapterUrlAccess);		-- Contribution is also in Chapter&lt;br /&gt;
		if utilities.is_set (Chapter) then&lt;br /&gt;
			Chapter = Chapter .. ChapterFormat ;&lt;br /&gt;
			if 'map' == config.CitationClass and utilities.is_set (TitleType) then&lt;br /&gt;
				Chapter = Chapter .. ' ' .. TitleType;							-- map annotation here; not after title&lt;br /&gt;
			end&lt;br /&gt;
			Chapter = Chapter .. sepc .. ' ';&lt;br /&gt;
		elseif utilities.is_set (ChapterFormat) then							-- |chapter= not set but |chapter-format= is so ...&lt;br /&gt;
			Chapter = ChapterFormat .. sepc .. ' ';								-- ... ChapterFormat has error message, we want to see it&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Format main title&lt;br /&gt;
	local plain_title = false;&lt;br /&gt;
	local accept_title;&lt;br /&gt;
	Title, accept_title = utilities.has_accept_as_written (Title, true);		-- remove accept-this-as-written markup when it wraps all of &amp;lt;Title&amp;gt;&lt;br /&gt;
	if accept_title and ('' == Title) then										-- only support forced empty for now &amp;quot;(())&amp;quot;&lt;br /&gt;
		Title = cfg.messages['notitle'];										-- replace by predefined &amp;quot;No title&amp;quot; message&lt;br /&gt;
			-- TODO: utilities.set_message ( 'err_redundant_parameters', ...);	-- issue proper error message instead of muting	 &lt;br /&gt;
			ScriptTitle = '';													-- just mute for now	 &lt;br /&gt;
			TransTitle = '';													-- just mute for now&lt;br /&gt;
 		plain_title = true;														-- suppress text decoration for descriptive title&lt;br /&gt;
		utilities.set_message ('maint_untitled');								-- add maint cat&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if not accept_title then -- &amp;lt;Title&amp;gt; not wrapped in accept-as-written markup&lt;br /&gt;
		if '...' == Title:sub (-3) then											-- if ellipsis is the last three characters of |title=&lt;br /&gt;
			Title = Title:gsub ('(%.%.%.)%.+$', '%1');							-- limit the number of dots to three&lt;br /&gt;
		elseif not mw.ustring.find (Title, '%.%s*%a%.$') and					-- end of title is not a 'dot-(optional space-)letter-dot' initialism ...&lt;br /&gt;
			not mw.ustring.find (Title, '%s+%a%.$') then						-- ...and not a 'space-letter-dot' initial (''Allium canadense'' L.)&lt;br /&gt;
				Title = mw.ustring.gsub(Title, '%' .. sepc .. '$', '');			-- remove any trailing separator character; sepc and ms.ustring() here for languages that use multibyte separator characters&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
		if utilities.is_set (ArchiveURL) and is_archived_copy (Title) then&lt;br /&gt;
			utilities.set_message ('maint_archived_copy');						-- add maintenance category before we modify the content of Title&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
		if is_generic_title (Title) then&lt;br /&gt;
			table.insert (z.message_tail, {utilities.set_message ( 'err_generic_title', {}, true ) } );	-- set an error message&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if (not plain_title) and (utilities.in_array (config.CitationClass, {'web', 'news', 'journal', 'magazine', 'pressrelease', 'podcast', 'newsgroup', 'mailinglist', 'interview', 'arxiv', 'biorxiv', 'citeseerx', 'ssrn'}) or&lt;br /&gt;
		('citation' == config.CitationClass and (utilities.is_set (Periodical) or utilities.is_set (ScriptPeriodical)) and not utilities.is_set (Encyclopedia)) or&lt;br /&gt;
		('map' == config.CitationClass and (utilities.is_set (Periodical) or utilities.is_set (ScriptPeriodical)))) then		-- special case for cite map when the map is in a periodical treat as an article&lt;br /&gt;
			Title = kern_quotes (Title);										-- if necessary, separate title's leading and trailing quote marks from module provided quote marks&lt;br /&gt;
			Title = utilities.wrap_style ('quoted-title', Title);&lt;br /&gt;
			Title = script_concatenate (Title, ScriptTitle, 'script-title');	-- &amp;lt;bdi&amp;gt; tags, lang attribute, categorization, etc.; must be done after title is wrapped&lt;br /&gt;
			TransTitle = utilities.wrap_style ('trans-quoted-title', TransTitle );&lt;br /&gt;
	elseif plain_title or ('report' == config.CitationClass) then								-- no styling for cite report and descriptive titles (otherwise same as above)&lt;br /&gt;
		Title = script_concatenate (Title, ScriptTitle, 'script-title');		-- &amp;lt;bdi&amp;gt; tags, lang attribute, categorization, etc.; must be done after title is wrapped&lt;br /&gt;
		TransTitle = utilities.wrap_style ('trans-quoted-title', TransTitle );				-- for cite report, use this form for trans-title&lt;br /&gt;
	else&lt;br /&gt;
		Title = utilities.wrap_style ('italic-title', Title);&lt;br /&gt;
		Title = script_concatenate (Title, ScriptTitle, 'script-title');		-- &amp;lt;bdi&amp;gt; tags, lang attribute, categorization, etc.; must be done after title is wrapped&lt;br /&gt;
		TransTitle = utilities.wrap_style ('trans-italic-title', TransTitle);&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local TransError = &amp;quot;&amp;quot;;&lt;br /&gt;
	if utilities.is_set (TransTitle) then&lt;br /&gt;
		if utilities.is_set (Title) then&lt;br /&gt;
			TransTitle = &amp;quot; &amp;quot; .. TransTitle;&lt;br /&gt;
		else&lt;br /&gt;
			TransError = &amp;quot; &amp;quot; .. utilities.set_message ( 'err_trans_missing_title', {'title'} );&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if utilities.is_set (Title) then											-- TODO: is this the right place to be making Wikisource URLs?&lt;br /&gt;
		if utilities.is_set (TitleLink) and utilities.is_set (URL) then&lt;br /&gt;
			table.insert( z.message_tail, { utilities.set_message ( 'err_wikilink_in_url', {}, true ) } );	-- set an error message because we can't have both&lt;br /&gt;
			TitleLink = '';														-- unset&lt;br /&gt;
		end&lt;br /&gt;
		&lt;br /&gt;
		if not utilities.is_set (TitleLink) and utilities.is_set (URL) then&lt;br /&gt;
			Title = external_link (URL, Title, URL_origin, UrlAccess) .. TransTitle .. TransError .. Format;&lt;br /&gt;
			URL = '';															-- unset these because no longer needed&lt;br /&gt;
			Format = &amp;quot;&amp;quot;;&lt;br /&gt;
		elseif utilities.is_set (TitleLink) and not utilities.is_set (URL) then&lt;br /&gt;
			local ws_url;&lt;br /&gt;
			ws_url = wikisource_url_make (TitleLink);							-- ignore ws_label return; not used here&lt;br /&gt;
			if ws_url then&lt;br /&gt;
				Title = external_link (ws_url, Title .. '&amp;amp;nbsp;', 'ws link in title-link');	-- space char after Title to move icon away from italic text; TODO: a better way to do this?&lt;br /&gt;
				Title = utilities.substitute (cfg.presentation['interwiki-icon'], {cfg.presentation['class-wikisource'], TitleLink, Title});				&lt;br /&gt;
				Title = Title .. TransTitle .. TransError;&lt;br /&gt;
			else&lt;br /&gt;
				Title = utilities.make_wikilink (TitleLink, Title) .. TransTitle .. TransError;&lt;br /&gt;
			end&lt;br /&gt;
		else&lt;br /&gt;
			local ws_url, ws_label, L;											-- Title has italic or quote markup by the time we get here which causes is_wikilink() to return 0 (not a wikilink)&lt;br /&gt;
			ws_url, ws_label, L = wikisource_url_make (Title:gsub('[\'&amp;quot;](.-)[\'&amp;quot;]', '%1'));	-- make ws URL from |title= interwiki link (strip italic or quote markup); link portion L becomes tooltip label&lt;br /&gt;
			if ws_url then&lt;br /&gt;
				Title = Title:gsub ('%b[]', ws_label);							-- replace interwiki link with ws_label to retain markup&lt;br /&gt;
				Title = external_link (ws_url, Title .. '&amp;amp;nbsp;', 'ws link in title');	-- space char after Title to move icon away from italic text; TODO: a better way to do this?&lt;br /&gt;
				Title = utilities.substitute (cfg.presentation['interwiki-icon'], {cfg.presentation['class-wikisource'], L, Title});				&lt;br /&gt;
				Title = Title .. TransTitle .. TransError;&lt;br /&gt;
			else&lt;br /&gt;
				Title = Title .. TransTitle .. TransError;&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	else&lt;br /&gt;
		Title = TransTitle .. TransError;&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if utilities.is_set (Place) then&lt;br /&gt;
		Place = &amp;quot; &amp;quot; .. wrap_msg ('written', Place, use_lowercase) .. sepc .. &amp;quot; &amp;quot;;&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if utilities.is_set (Conference) then&lt;br /&gt;
		if utilities.is_set (ConferenceURL) then&lt;br /&gt;
			Conference = external_link( ConferenceURL, Conference, ConferenceURL_origin, nil );&lt;br /&gt;
		end&lt;br /&gt;
		Conference = sepc .. &amp;quot; &amp;quot; .. Conference .. ConferenceFormat;&lt;br /&gt;
	elseif utilities.is_set (ConferenceURL) then&lt;br /&gt;
		Conference = sepc .. &amp;quot; &amp;quot; .. external_link( ConferenceURL, nil, ConferenceURL_origin, nil );&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if not utilities.is_set (Position) then&lt;br /&gt;
		local Minutes = A['Minutes'];&lt;br /&gt;
		local Time = A['Time'];&lt;br /&gt;
&lt;br /&gt;
		if utilities.is_set (Minutes) then&lt;br /&gt;
			if utilities.is_set (Time) then&lt;br /&gt;
				table.insert( z.message_tail, { utilities.set_message ( 'err_redundant_parameters', {utilities.wrap_style ('parameter', 'minutes') .. ' and ' .. utilities.wrap_style ('parameter', 'time')}, true ) } );&lt;br /&gt;
			end&lt;br /&gt;
			Position = &amp;quot; &amp;quot; .. Minutes .. &amp;quot; &amp;quot; .. cfg.messages['minutes'];&lt;br /&gt;
		else&lt;br /&gt;
			if utilities.is_set (Time) then&lt;br /&gt;
				local TimeCaption = A['TimeCaption']&lt;br /&gt;
				if not utilities.is_set (TimeCaption) then&lt;br /&gt;
					TimeCaption = cfg.messages['event'];&lt;br /&gt;
					if sepc ~= '.' then&lt;br /&gt;
						TimeCaption = TimeCaption:lower();&lt;br /&gt;
					end&lt;br /&gt;
				end&lt;br /&gt;
				Position = &amp;quot; &amp;quot; .. TimeCaption .. &amp;quot; &amp;quot; .. Time;&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	else&lt;br /&gt;
		Position = &amp;quot; &amp;quot; .. Position;&lt;br /&gt;
		At = '';&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	Page, Pages, Sheet, Sheets = format_pages_sheets (Page, Pages, Sheet, Sheets, config.CitationClass, Periodical_origin, sepc, NoPP, use_lowercase);&lt;br /&gt;
&lt;br /&gt;
	At = utilities.is_set (At) and (sepc .. &amp;quot; &amp;quot; .. At) or &amp;quot;&amp;quot;;&lt;br /&gt;
	Position = utilities.is_set (Position) and (sepc .. &amp;quot; &amp;quot; .. Position) or &amp;quot;&amp;quot;;&lt;br /&gt;
	if config.CitationClass == 'map' then&lt;br /&gt;
		local Sections = A['Sections'];											-- Section (singular) is an alias of Chapter so set earlier&lt;br /&gt;
		local Inset = A['Inset'];&lt;br /&gt;
		&lt;br /&gt;
		if utilities.is_set ( Inset ) then&lt;br /&gt;
			Inset = sepc .. &amp;quot; &amp;quot; .. wrap_msg ('inset', Inset, use_lowercase);&lt;br /&gt;
		end			&lt;br /&gt;
&lt;br /&gt;
		if utilities.is_set ( Sections ) then&lt;br /&gt;
			Section = sepc .. &amp;quot; &amp;quot; .. wrap_msg ('sections', Sections, use_lowercase);&lt;br /&gt;
		elseif utilities.is_set ( Section ) then&lt;br /&gt;
			Section = sepc .. &amp;quot; &amp;quot; .. wrap_msg ('section', Section, use_lowercase);&lt;br /&gt;
		end&lt;br /&gt;
		At = At .. Inset .. Section;		&lt;br /&gt;
	end	&lt;br /&gt;
&lt;br /&gt;
	if utilities.is_set (Language) then&lt;br /&gt;
		Language = language_parameter (Language);								-- format, categories, name from ISO639-1, etc.&lt;br /&gt;
	else&lt;br /&gt;
		Language=&amp;quot;&amp;quot;;															-- language not specified so make sure this is an empty string;&lt;br /&gt;
	--[[ TODO: need to extract the wrap_msg from language_parameter&lt;br /&gt;
	so that we can solve parentheses bunching problem with Format/Language/TitleType&lt;br /&gt;
	]]&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	Others = utilities.is_set (Others) and (sepc .. &amp;quot; &amp;quot; .. Others) or &amp;quot;&amp;quot;;&lt;br /&gt;
	&lt;br /&gt;
	if utilities.is_set (Translators) then&lt;br /&gt;
		Others = safe_join ({sepc .. ' ', wrap_msg ('translated', Translators, use_lowercase), Others}, sepc);&lt;br /&gt;
	end&lt;br /&gt;
	if utilities.is_set (Interviewers) then&lt;br /&gt;
		Others = safe_join ({sepc .. ' ', wrap_msg ('interview', Interviewers, use_lowercase), Others}, sepc);&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	TitleNote = utilities.is_set (TitleNote) and (sepc .. &amp;quot; &amp;quot; .. TitleNote) or &amp;quot;&amp;quot;;&lt;br /&gt;
	if utilities.is_set (Edition) then&lt;br /&gt;
		if Edition:match ('%f[%a][Ee]d%.?$') or Edition:match ('%f[%a][Ee]dition$') then&lt;br /&gt;
			utilities.set_message ('maint_extra_text', 'edition');				-- add maint cat&lt;br /&gt;
		end&lt;br /&gt;
		Edition = &amp;quot; &amp;quot; .. wrap_msg ('edition', Edition);&lt;br /&gt;
	else&lt;br /&gt;
		Edition = '';&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	Series = utilities.is_set (Series) and wrap_msg ('series', {sepc, Series}) or &amp;quot;&amp;quot;;	-- not the same as SeriesNum&lt;br /&gt;
	OrigDate = utilities.is_set (OrigDate) and wrap_msg ('origdate', OrigDate) or '';&lt;br /&gt;
	Agency = utilities.is_set (Agency) and wrap_msg ('agency', {sepc, Agency}) or &amp;quot;&amp;quot;;&lt;br /&gt;
	Volume = format_volume_issue (Volume, Issue, config.CitationClass, Periodical_origin, sepc, use_lowercase);&lt;br /&gt;
&lt;br /&gt;
	------------------------------------ totally unrelated data&lt;br /&gt;
	Via = utilities.is_set (Via) and  wrap_msg ('via', Via) or '';&lt;br /&gt;
&lt;br /&gt;
	if utilities.is_set (AccessDate) then&lt;br /&gt;
		local retrv_text = &amp;quot; &amp;quot; .. cfg.messages['retrieved']&lt;br /&gt;
&lt;br /&gt;
		AccessDate = nowrap_date (AccessDate);									-- wrap in nowrap span if date in appropriate format&lt;br /&gt;
		if (sepc ~= &amp;quot;.&amp;quot;) then retrv_text = retrv_text:lower() end				-- if mode is cs2, lower case&lt;br /&gt;
		AccessDate = utilities.substitute (retrv_text, AccessDate);				-- add retrieved text&lt;br /&gt;
&lt;br /&gt;
		AccessDate = utilities.substitute (cfg.presentation['accessdate'], {sepc, AccessDate});	-- allow editors to hide accessdates&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	if utilities.is_set (ID) then ID = sepc .. &amp;quot; &amp;quot; .. ID; end&lt;br /&gt;
   	if &amp;quot;thesis&amp;quot; == config.CitationClass and utilities.is_set (Docket) then&lt;br /&gt;
		ID = sepc .. &amp;quot; Docket &amp;quot; .. Docket .. ID;&lt;br /&gt;
	end&lt;br /&gt;
   	if &amp;quot;report&amp;quot; == config.CitationClass and utilities.is_set (Docket) then		-- for cite report when |docket= is set&lt;br /&gt;
		ID = sepc .. ' ' .. Docket;												-- overwrite ID even if |id= is set&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if utilities.is_set (URL) then&lt;br /&gt;
		URL = &amp;quot; &amp;quot; .. external_link( URL, nil, URL_origin, UrlAccess );&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if utilities.is_set (Quote) or utilities.is_set (TransQuote) or utilities.is_set (ScriptQuote) then&lt;br /&gt;
&lt;br /&gt;
		if utilities.is_set (Quote) then&lt;br /&gt;
			if Quote:sub(1, 1) == '&amp;quot;' and Quote:sub(-1, -1) == '&amp;quot;' then			-- if first and last characters of quote are quote marks&lt;br /&gt;
				Quote = Quote:sub(2, -2);										-- strip them off&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
		Quote = utilities.wrap_style ('quoted-text', Quote ); 	-- wrap in &amp;lt;q&amp;gt;...&amp;lt;/q&amp;gt; tags&lt;br /&gt;
	&lt;br /&gt;
		if utilities.is_set (ScriptQuote) then&lt;br /&gt;
			Quote = script_concatenate (Quote, ScriptQuote, 'script-quote'); -- &amp;lt;bdi&amp;gt; tags, lang attribute, categorization, etc.; must be done after quote is wrapped&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
		if utilities.is_set (TransQuote) then&lt;br /&gt;
			if TransQuote:sub(1, 1) == '&amp;quot;' and TransQuote:sub(-1, -1) == '&amp;quot;' then -- if first and last characters of |trans-quote are quote marks&lt;br /&gt;
				TransQuote = TransQuote:sub(2, -2); -- strip them off&lt;br /&gt;
			end&lt;br /&gt;
			Quote = Quote .. &amp;quot; &amp;quot; .. utilities.wrap_style ('trans-quoted-title', TransQuote );&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
		if utilities.is_set (QuotePage) or utilities.is_set (QuotePages) then	-- add page prefix&lt;br /&gt;
			local quote_prefix = '';&lt;br /&gt;
			if utilities.is_set (QuotePage) then&lt;br /&gt;
				if not NoPP then&lt;br /&gt;
					quote_prefix = utilities.substitute (cfg.messages['p-prefix'], {sepc, QuotePage}), '', '', '';&lt;br /&gt;
				else&lt;br /&gt;
					quote_prefix = utilities.substitute (cfg.messages['nopp'], {sepc, QuotePage}), '', '', '';&lt;br /&gt;
				end&lt;br /&gt;
			elseif utilities.is_set (QuotePages) then&lt;br /&gt;
				if tonumber(QuotePages) ~= nil and not NoPP then				-- if only digits, assume single page&lt;br /&gt;
					quote_prefix = utilities.substitute (cfg.messages['p-prefix'], {sepc, QuotePages}), '', '';&lt;br /&gt;
				elseif not NoPP then&lt;br /&gt;
					quote_prefix = utilities.substitute (cfg.messages['pp-prefix'], {sepc, QuotePages}), '', '';&lt;br /&gt;
				else&lt;br /&gt;
					quote_prefix = utilities.substitute (cfg.messages['nopp'], {sepc, QuotePages}), '', '';&lt;br /&gt;
				end&lt;br /&gt;
			end&lt;br /&gt;
                        &lt;br /&gt;
			Quote = quote_prefix .. &amp;quot;: &amp;quot; .. Quote;&lt;br /&gt;
		else&lt;br /&gt;
			Quote = sepc .. &amp;quot; &amp;quot; .. Quote;&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
		PostScript = &amp;quot;&amp;quot;;														-- cs1|2 does not supply terminal punctuation when |quote= is set&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	local Archived&lt;br /&gt;
	if utilities.is_set (ArchiveURL) then&lt;br /&gt;
		local arch_text;&lt;br /&gt;
		if not utilities.is_set (ArchiveDate) then&lt;br /&gt;
			ArchiveDate = utilities.set_message ('err_archive_missing_date');&lt;br /&gt;
		end&lt;br /&gt;
		if &amp;quot;live&amp;quot; == UrlStatus then&lt;br /&gt;
			arch_text = cfg.messages['archived'];&lt;br /&gt;
			if sepc ~= &amp;quot;.&amp;quot; then arch_text = arch_text:lower() end&lt;br /&gt;
			Archived = sepc .. &amp;quot; &amp;quot; .. utilities.substitute ( cfg.messages['archived-live'],&lt;br /&gt;
				{ external_link( ArchiveURL, arch_text, A:ORIGIN('ArchiveURL'), nil ) .. ArchiveFormat, ArchiveDate } );&lt;br /&gt;
			if not utilities.is_set (OriginalURL) then&lt;br /&gt;
				Archived = Archived .. &amp;quot; &amp;quot; .. utilities.set_message ('err_archive_missing_url');							   &lt;br /&gt;
			end&lt;br /&gt;
		elseif utilities.is_set (OriginalURL) then								-- UrlStatus is empty, 'dead', 'unfit', 'usurped', 'bot: unknown'&lt;br /&gt;
			if utilities.in_array (UrlStatus, {'unfit', 'usurped', 'bot: unknown'}) then&lt;br /&gt;
				arch_text = cfg.messages['archived-unfit'];&lt;br /&gt;
				if sepc ~= &amp;quot;.&amp;quot; then arch_text = arch_text:lower() end&lt;br /&gt;
				Archived = sepc .. &amp;quot; &amp;quot; .. arch_text .. ArchiveDate;				-- format already styled&lt;br /&gt;
				if 'bot: unknown' == UrlStatus then&lt;br /&gt;
					utilities.set_message ('maint_bot_unknown');				-- and add a category if not already added&lt;br /&gt;
				else&lt;br /&gt;
					utilities.set_message ('maint_unfit');						-- and add a category if not already added&lt;br /&gt;
				end&lt;br /&gt;
			else																-- UrlStatus is empty, 'dead'&lt;br /&gt;
				arch_text = cfg.messages['archived-dead'];&lt;br /&gt;
				if sepc ~= &amp;quot;.&amp;quot; then arch_text = arch_text:lower() end&lt;br /&gt;
				Archived = sepc .. &amp;quot; &amp;quot; .. utilities.substitute ( arch_text,&lt;br /&gt;
					{ external_link( OriginalURL, cfg.messages['original'], OriginalURL_origin, OriginalAccess ) .. OriginalFormat, ArchiveDate } );	-- format already styled&lt;br /&gt;
			end	&lt;br /&gt;
		else																	-- OriginalUrl not set&lt;br /&gt;
			arch_text = cfg.messages['archived-missing'];&lt;br /&gt;
			if sepc ~= &amp;quot;.&amp;quot; then arch_text = arch_text:lower() end&lt;br /&gt;
			Archived = sepc .. &amp;quot; &amp;quot; .. utilities.substitute ( arch_text, &lt;br /&gt;
				{ utilities.set_message ('err_archive_missing_url'), ArchiveDate } );&lt;br /&gt;
		end&lt;br /&gt;
	elseif utilities.is_set (ArchiveFormat) then&lt;br /&gt;
		Archived = ArchiveFormat;												-- if set and ArchiveURL not set ArchiveFormat has error message&lt;br /&gt;
	else&lt;br /&gt;
		Archived = &amp;quot;&amp;quot;&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	local Lay = '';&lt;br /&gt;
	if utilities.is_set (LayURL) then&lt;br /&gt;
		if utilities.is_set (LayDate) then LayDate = &amp;quot; (&amp;quot; .. LayDate .. &amp;quot;)&amp;quot; end&lt;br /&gt;
		if utilities.is_set (LaySource) then &lt;br /&gt;
			LaySource = &amp;quot; &amp;amp;ndash; ''&amp;quot; .. utilities.safe_for_italics (LaySource) .. &amp;quot;''&amp;quot;;&lt;br /&gt;
		else&lt;br /&gt;
			LaySource = &amp;quot;&amp;quot;;&lt;br /&gt;
		end&lt;br /&gt;
		if sepc == '.' then&lt;br /&gt;
			Lay = sepc .. &amp;quot; &amp;quot; .. external_link( LayURL, cfg.messages['lay summary'], A:ORIGIN('LayURL'), nil ) .. LayFormat .. LaySource .. LayDate&lt;br /&gt;
		else&lt;br /&gt;
			Lay = sepc .. &amp;quot; &amp;quot; .. external_link( LayURL, cfg.messages['lay summary']:lower(), A:ORIGIN('LayURL'), nil ) .. LayFormat .. LaySource .. LayDate&lt;br /&gt;
		end			&lt;br /&gt;
	elseif utilities.is_set (LayFormat) then									-- Test if |lay-format= is given without giving a |lay-url=&lt;br /&gt;
		Lay = sepc .. LayFormat;												-- if set and LayURL not set, then LayFormat has error message&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if utilities.is_set (Transcript) then&lt;br /&gt;
		if utilities.is_set (TranscriptURL) then&lt;br /&gt;
			Transcript = external_link( TranscriptURL, Transcript, TranscriptURL_origin, nil );&lt;br /&gt;
		end&lt;br /&gt;
		Transcript = sepc .. ' ' .. Transcript .. TranscriptFormat;&lt;br /&gt;
	elseif utilities.is_set (TranscriptURL) then&lt;br /&gt;
		Transcript = external_link( TranscriptURL, nil, TranscriptURL_origin, nil );&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local Publisher;&lt;br /&gt;
	if utilities.is_set (PublicationDate) then&lt;br /&gt;
		PublicationDate = wrap_msg ('published', PublicationDate);&lt;br /&gt;
	end&lt;br /&gt;
	if utilities.is_set (PublisherName) then&lt;br /&gt;
		if utilities.is_set (PublicationPlace) then&lt;br /&gt;
			Publisher = sepc .. &amp;quot; &amp;quot; .. PublicationPlace .. &amp;quot;: &amp;quot; .. PublisherName .. PublicationDate;&lt;br /&gt;
		else&lt;br /&gt;
			Publisher = sepc .. &amp;quot; &amp;quot; .. PublisherName .. PublicationDate;  &lt;br /&gt;
		end			&lt;br /&gt;
	elseif utilities.is_set (PublicationPlace) then &lt;br /&gt;
		Publisher= sepc .. &amp;quot; &amp;quot; .. PublicationPlace .. PublicationDate;&lt;br /&gt;
	else &lt;br /&gt;
		Publisher = PublicationDate;&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	-- Several of the above rely upon detecting this as nil, so do it last.&lt;br /&gt;
	if (utilities.is_set (Periodical) or utilities.is_set (ScriptPeriodical) or utilities.is_set (TransPeriodical)) then&lt;br /&gt;
		if utilities.is_set (Title) or utilities.is_set (TitleNote) then &lt;br /&gt;
			Periodical = sepc .. &amp;quot; &amp;quot; .. format_periodical (ScriptPeriodical, ScriptPeriodical_origin, Periodical, TransPeriodical, TransPeriodical_origin);&lt;br /&gt;
		else &lt;br /&gt;
			Periodical = format_periodical (ScriptPeriodical, ScriptPeriodical_origin, Periodical, TransPeriodical, TransPeriodical_origin);&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	--[[&lt;br /&gt;
	Handle the oddity that is cite speech.  This code overrides whatever may be the value assigned to TitleNote (through |department=) and forces it to be &amp;quot; (Speech)&amp;quot; so that&lt;br /&gt;
	the annotation directly follows the |title= parameter value in the citation rather than the |event= parameter value (if provided).&lt;br /&gt;
	]]&lt;br /&gt;
	if &amp;quot;speech&amp;quot; == config.CitationClass then									-- cite speech only&lt;br /&gt;
		TitleNote = &amp;quot; (Speech)&amp;quot;;												-- annotate the citation&lt;br /&gt;
		if utilities.is_set (Periodical) then									-- if Periodical, perhaps because of an included |website= or |journal= parameter &lt;br /&gt;
			if utilities.is_set (Conference) then								-- and if |event= is set&lt;br /&gt;
				Conference = Conference .. sepc .. &amp;quot; &amp;quot;;							-- then add appropriate punctuation to the end of the Conference variable before rendering&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Piece all bits together at last.  Here, all should be non-nil.&lt;br /&gt;
	-- We build things this way because it is more efficient in LUA&lt;br /&gt;
	-- not to keep reassigning to the same string variable over and over.&lt;br /&gt;
&lt;br /&gt;
	local tcommon;&lt;br /&gt;
	local tcommon2;																-- used for book cite when |contributor= is set&lt;br /&gt;
	&lt;br /&gt;
	if utilities.in_array (config.CitationClass, {&amp;quot;journal&amp;quot;, &amp;quot;citation&amp;quot;}) and utilities.is_set (Periodical) then&lt;br /&gt;
		if utilities.is_set (Others) then Others = safe_join ({Others, sepc .. &amp;quot; &amp;quot;}, sepc) end		-- add terminal punctuation &amp;amp; space; check for dup sepc; TODO why do we need to do this here?&lt;br /&gt;
		tcommon = safe_join( {Others, Title, TitleNote, Conference, Periodical, Format, TitleType, Series, Language, Edition, Publisher, Agency, Volume}, sepc );&lt;br /&gt;
	elseif utilities.in_array (config.CitationClass, {&amp;quot;book&amp;quot;, &amp;quot;citation&amp;quot;}) and not utilities.is_set (Periodical) then		-- special cases for book cites&lt;br /&gt;
		if utilities.is_set (Contributors) then									-- when we are citing foreword, preface, introduction, etc.&lt;br /&gt;
			tcommon = safe_join( {Title, TitleNote}, sepc );					-- author and other stuff will come after this and before tcommon2&lt;br /&gt;
			tcommon2 = safe_join( {Conference, Periodical, Format, TitleType, Series, Language, Volume, Others, Edition, Publisher, Agency}, sepc );&lt;br /&gt;
		else&lt;br /&gt;
			tcommon = safe_join( {Title, TitleNote, Conference, Periodical, Format, TitleType, Series, Language, Volume, Others, Edition, Publisher, Agency}, sepc );&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
	elseif 'map' == config.CitationClass then									-- special cases for cite map&lt;br /&gt;
		if utilities.is_set (Chapter) then										-- map in a book; TitleType is part of Chapter&lt;br /&gt;
			tcommon = safe_join( {Title, Format, Edition, Scale, Series, Language, Cartography, Others, Publisher, Volume}, sepc );&lt;br /&gt;
		elseif utilities.is_set (Periodical) then								-- map in a periodical&lt;br /&gt;
			tcommon = safe_join( {Title, TitleType, Format, Periodical, Scale, Series, Language, Cartography, Others, Publisher, Volume}, sepc );&lt;br /&gt;
		else																	-- a sheet or stand-alone map&lt;br /&gt;
			tcommon = safe_join( {Title, TitleType, Format, Edition, Scale, Series, Language, Cartography, Others, Publisher}, sepc );&lt;br /&gt;
		end&lt;br /&gt;
		&lt;br /&gt;
	elseif 'episode' == config.CitationClass then								-- special case for cite episode&lt;br /&gt;
		tcommon = safe_join( {Title, TitleNote, TitleType, Series, Language, Edition, Publisher}, sepc );&lt;br /&gt;
&lt;br /&gt;
	else																		-- all other CS1 templates&lt;br /&gt;
		tcommon = safe_join( {Title, TitleNote, Conference, Periodical, Format, TitleType, Series, Language, &lt;br /&gt;
			Volume, Others, Edition, Publisher, Agency}, sepc );&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	if #ID_list &amp;gt; 0 then&lt;br /&gt;
		ID_list = safe_join( { sepc .. &amp;quot; &amp;quot;,  table.concat( ID_list, sepc .. &amp;quot; &amp;quot; ), ID }, sepc );&lt;br /&gt;
	else&lt;br /&gt;
		ID_list = ID;&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	local idcommon;&lt;br /&gt;
	if 'audio-visual' == config.CitationClass or 'episode' == config.CitationClass then	-- special case for cite AV media &amp;amp; cite episode position transcript&lt;br /&gt;
		idcommon = safe_join( { ID_list, URL, Archived, Transcript, AccessDate, Via, Lay, Quote }, sepc );&lt;br /&gt;
	else&lt;br /&gt;
		idcommon = safe_join( { ID_list, URL, Archived, AccessDate, Via, Lay, Quote }, sepc );&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	local text;&lt;br /&gt;
	local pgtext = Position .. Sheet .. Sheets .. Page .. Pages .. At;&lt;br /&gt;
&lt;br /&gt;
	if utilities.is_set (Date) then&lt;br /&gt;
		if utilities.is_set (Authors) or utilities.is_set (Editors) then		-- date follows authors or editors when authors not set&lt;br /&gt;
			Date = &amp;quot; (&amp;quot; .. Date .. &amp;quot;)&amp;quot; .. OrigDate .. sepc .. &amp;quot; &amp;quot;;				-- in parentheses&lt;br /&gt;
		else																	-- neither of authors and editors set&lt;br /&gt;
			if (string.sub(tcommon, -1, -1) == sepc) then						-- if the last character of tcommon is sepc&lt;br /&gt;
				Date = &amp;quot; &amp;quot; .. Date .. OrigDate;									-- Date does not begin with sepc&lt;br /&gt;
			else&lt;br /&gt;
				Date = sepc .. &amp;quot; &amp;quot; .. Date .. OrigDate;							-- Date begins with sepc&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	end	&lt;br /&gt;
	if utilities.is_set (Authors) then&lt;br /&gt;
		if (not utilities.is_set (Date)) then									-- when date is set it's in parentheses; no Authors termination&lt;br /&gt;
			Authors = terminate_name_list (Authors, sepc);						-- when no date, terminate with 0 or 1 sepc and a space&lt;br /&gt;
		end&lt;br /&gt;
		if utilities.is_set (Editors) then&lt;br /&gt;
			local in_text = &amp;quot; &amp;quot;;&lt;br /&gt;
			local post_text = &amp;quot;&amp;quot;;&lt;br /&gt;
			if utilities.is_set (Chapter) and 0 == #c then&lt;br /&gt;
				in_text = in_text .. cfg.messages['in'] .. &amp;quot; &amp;quot;&lt;br /&gt;
				if (sepc ~= '.') then&lt;br /&gt;
					in_text = in_text:lower()									-- lowercase for cs2&lt;br /&gt;
				end&lt;br /&gt;
			end&lt;br /&gt;
			if EditorCount &amp;lt;= 1 then&lt;br /&gt;
				post_text = &amp;quot; (&amp;quot; .. cfg.messages['editor'] .. &amp;quot;)&amp;quot;;				-- be consistent with no-author, no-date case&lt;br /&gt;
			else&lt;br /&gt;
				post_text = &amp;quot; (&amp;quot; .. cfg.messages['editors'] .. &amp;quot;)&amp;quot;;&lt;br /&gt;
			end&lt;br /&gt;
			Editors = terminate_name_list (in_text .. Editors .. post_text, sepc);	-- terminate with 0 or 1 sepc and a space&lt;br /&gt;
		end&lt;br /&gt;
		if utilities.is_set (Contributors) then									-- book cite and we're citing the intro, preface, etc.&lt;br /&gt;
			local by_text = sepc .. ' ' .. cfg.messages['by'] .. ' ';&lt;br /&gt;
			if (sepc ~= '.') then by_text = by_text:lower() end					-- lowercase for cs2&lt;br /&gt;
			Authors = by_text .. Authors;										-- author follows title so tweak it here&lt;br /&gt;
			if utilities.is_set (Editors) and utilities.is_set (Date) then		-- when Editors make sure that Authors gets terminated&lt;br /&gt;
				Authors = terminate_name_list (Authors, sepc);					-- terminate with 0 or 1 sepc and a space&lt;br /&gt;
			end&lt;br /&gt;
			if (not utilities.is_set (Date)) then								-- when date is set it's in parentheses; no Contributors termination&lt;br /&gt;
				Contributors = terminate_name_list (Contributors, sepc);		-- terminate with 0 or 1 sepc and a space&lt;br /&gt;
			end&lt;br /&gt;
			text = safe_join( {Contributors, Date, Chapter, tcommon, Authors, Place, Editors, tcommon2, pgtext, idcommon }, sepc );&lt;br /&gt;
		else&lt;br /&gt;
			text = safe_join( {Authors, Date, Chapter, Place, Editors, tcommon, pgtext, idcommon }, sepc );&lt;br /&gt;
		end&lt;br /&gt;
	elseif utilities.is_set (Editors) then&lt;br /&gt;
		if utilities.is_set (Date) then&lt;br /&gt;
			if EditorCount &amp;lt;= 1 then&lt;br /&gt;
				Editors = Editors .. &amp;quot;, &amp;quot; .. cfg.messages['editor'];&lt;br /&gt;
			else&lt;br /&gt;
				Editors = Editors .. &amp;quot;, &amp;quot; .. cfg.messages['editors'];&lt;br /&gt;
			end&lt;br /&gt;
		else&lt;br /&gt;
			if EditorCount &amp;lt;= 1 then&lt;br /&gt;
				Editors = Editors .. &amp;quot; (&amp;quot; .. cfg.messages['editor'] .. &amp;quot;)&amp;quot; .. sepc .. &amp;quot; &amp;quot;&lt;br /&gt;
			else&lt;br /&gt;
				Editors = Editors .. &amp;quot; (&amp;quot; .. cfg.messages['editors'] .. &amp;quot;)&amp;quot; .. sepc .. &amp;quot; &amp;quot;&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
		text = safe_join( {Editors, Date, Chapter, Place, tcommon, pgtext, idcommon}, sepc );&lt;br /&gt;
	else&lt;br /&gt;
		if utilities.in_array (config.CitationClass, {&amp;quot;journal&amp;quot;, &amp;quot;citation&amp;quot;}) and utilities.is_set (Periodical) then&lt;br /&gt;
			text = safe_join( {Chapter, Place, tcommon, pgtext, Date, idcommon}, sepc );&lt;br /&gt;
		else&lt;br /&gt;
			text = safe_join( {Chapter, Place, tcommon, Date, pgtext, idcommon}, sepc );&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	if utilities.is_set (PostScript) and PostScript ~= sepc then&lt;br /&gt;
		text = safe_join( {text, sepc}, sepc ); 								--Deals with italics, spaces, etc.&lt;br /&gt;
		text = text:sub(1, -sepc:len() - 1);&lt;br /&gt;
	end	&lt;br /&gt;
	&lt;br /&gt;
	text = safe_join( {text, PostScript}, sepc );&lt;br /&gt;
&lt;br /&gt;
	-- Now enclose the whole thing in a &amp;lt;cite/&amp;gt; element&lt;br /&gt;
	local options = {};&lt;br /&gt;
	&lt;br /&gt;
	if utilities.is_set (config.CitationClass) and config.CitationClass ~= &amp;quot;citation&amp;quot; then&lt;br /&gt;
		options.class = string.format ('%s %s %s', 'citation', config.CitationClass, utilities.is_set (Mode) and Mode or 'cs1');	-- class=citation required for blue highlight when used with |ref=&lt;br /&gt;
	else&lt;br /&gt;
		options.class = string.format ('%s %s', 'citation', utilities.is_set (Mode) and Mode or 'cs2');&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	if utilities.is_set (Ref) and 'none' ~= cfg.keywords_xlate[Ref:lower()] then&lt;br /&gt;
		local id = Ref&lt;br /&gt;
		if ('harv' == Ref ) then&lt;br /&gt;
			local namelist = {};												-- holds selected contributor, author, editor name list&lt;br /&gt;
			local year = first_set ({Year, anchor_year}, 2);					-- Year first for legacy citations and for YMD dates that require disambiguation&lt;br /&gt;
&lt;br /&gt;
			if #c &amp;gt; 0 then														-- if there is a contributor list&lt;br /&gt;
				namelist = c;													-- select it&lt;br /&gt;
			elseif #a &amp;gt; 0 then													-- or an author list&lt;br /&gt;
				namelist = a;&lt;br /&gt;
			elseif #e &amp;gt; 0 then													-- or an editor list&lt;br /&gt;
				namelist = e;&lt;br /&gt;
			end&lt;br /&gt;
			if #namelist &amp;gt; 0 then												-- if there are names in namelist&lt;br /&gt;
				id = anchor_id (namelist, year);								-- go make the CITEREF anchor&lt;br /&gt;
			else&lt;br /&gt;
				id = '';														-- unset&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
		options.id = id;&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	if string.len(text:gsub(&amp;quot;&amp;lt;span[^&amp;gt;/]*&amp;gt;(.-)&amp;lt;/span&amp;gt;&amp;quot;, &amp;quot;%1&amp;quot;):gsub(&amp;quot;%b&amp;lt;&amp;gt;&amp;quot;, &amp;quot;&amp;quot;)) &amp;lt;= 2 then	-- remove &amp;lt;span&amp;gt; tags and other HTML-like markup; then get length of what remains&lt;br /&gt;
		z.error_categories = {};&lt;br /&gt;
		text = utilities.set_message ('err_empty_citation');&lt;br /&gt;
		z.message_tail = {};&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	local render = {};															-- here we collect the final bits for concatenation into the rendered citation&lt;br /&gt;
&lt;br /&gt;
	if utilities.is_set (options.id) then										-- here we wrap the rendered citation in &amp;lt;cite ...&amp;gt;...&amp;lt;/cite&amp;gt; tags&lt;br /&gt;
		table.insert (render, utilities.substitute (cfg.presentation['cite-id'], {mw.uri.anchorEncode(options.id), mw.text.nowiki(options.class), text}));	-- when |ref= is set&lt;br /&gt;
	else&lt;br /&gt;
		table.insert (render, utilities.substitute (cfg.presentation['cite'], {mw.text.nowiki(options.class), text}));	-- all other cases&lt;br /&gt;
	end		&lt;br /&gt;
&lt;br /&gt;
	table.insert (render, utilities.substitute (cfg.presentation['ocins'], {OCinSoutput}));	-- append metadata to the citation&lt;br /&gt;
&lt;br /&gt;
	if 0 ~= #z.message_tail then&lt;br /&gt;
		table.insert (render, ' ');&lt;br /&gt;
		for i,v in ipairs( z.message_tail ) do&lt;br /&gt;
			if utilities.is_set (v[1]) then&lt;br /&gt;
				if i == #z.message_tail then&lt;br /&gt;
					table.insert (render, utilities.error_comment ( v[1], v[2] ));&lt;br /&gt;
				else&lt;br /&gt;
					table.insert (render, utilities.error_comment ( v[1] .. &amp;quot;; &amp;quot;, v[2] ));&lt;br /&gt;
				end&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if 0 ~= #z.maintenance_cats then&lt;br /&gt;
		local maint_msgs = {};													-- here we collect all of the maint messages&lt;br /&gt;
		for _, v in ipairs( z.maintenance_cats ) do								-- append maintenance categories&lt;br /&gt;
			local maint = {};													-- here we assemble a maintenence message&lt;br /&gt;
			table.insert (maint, v);											-- maint msg is the category name&lt;br /&gt;
			table.insert (maint, ' (');											-- open the link text&lt;br /&gt;
			table.insert (maint, utilities.make_wikilink (':Category:' .. v, 'link'));	-- add the link&lt;br /&gt;
			table.insert (maint, ')');											-- and close it&lt;br /&gt;
			table.insert (maint_msgs, table.concat (maint));					-- assemble new maint message and add it to the maint_msgs table&lt;br /&gt;
		end&lt;br /&gt;
		table.insert (render, utilities.substitute (cfg.presentation['hidden-maint'], table.concat (maint_msgs, ' ')));	-- wrap the group of maint message with proper presentation and save&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	if not no_tracking_cats then&lt;br /&gt;
		for _, v in ipairs( z.error_categories ) do&lt;br /&gt;
			table.insert (render, utilities.make_wikilink ('Category:' .. v));&lt;br /&gt;
		end&lt;br /&gt;
		for _, v in ipairs( z.maintenance_cats ) do								-- append maintenance categories&lt;br /&gt;
			table.insert (render, utilities.make_wikilink ('Category:' .. v));&lt;br /&gt;
		end&lt;br /&gt;
		for _, v in ipairs( z.properties_cats ) do								-- append properties categories&lt;br /&gt;
			table.insert (render, utilities.make_wikilink ('Category:' .. v));&lt;br /&gt;
		end&lt;br /&gt;
	elseif 'nocat' == A:ORIGIN('NoTracking') then								-- peculiar special case; can't track nocat without tracking nocat&lt;br /&gt;
		table.insert (render, utilities.make_wikilink ('Category:CS1 maint: nocat'));	-- hand-set this category because it is supposed to be temporary&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	return table.concat (render);	&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; V A L I D A T E &amp;gt;--------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Looks for a parameter's name in one of several whitelists.&lt;br /&gt;
&lt;br /&gt;
Parameters in the whitelist can have three values:&lt;br /&gt;
	true - active, supported parameters&lt;br /&gt;
	false - deprecated, supported parameters&lt;br /&gt;
	nil - unsupported parameters&lt;br /&gt;
	&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function validate (name, cite_class, empty)&lt;br /&gt;
	local name = tostring (name);&lt;br /&gt;
	local enum_name;															-- for enumerated parameters, is name with enumerator replaced with '#'&lt;br /&gt;
	local state;&lt;br /&gt;
	local function state_test (state, name)										-- local function to do testing of state values&lt;br /&gt;
		if true == state then return true; end									-- valid actively supported parameter&lt;br /&gt;
		if false == state then&lt;br /&gt;
			if empty then return nil; end										-- deprecated empty parameters are treated as unknowns&lt;br /&gt;
			deprecated_parameter (name);										-- parameter is deprecated but still supported&lt;br /&gt;
			return true;&lt;br /&gt;
		end&lt;br /&gt;
		return nil;&lt;br /&gt;
	end		&lt;br /&gt;
&lt;br /&gt;
	if name:find ('#') then														-- # is a cs1|2 reserved character so parameters with # not permitted&lt;br /&gt;
		return nil;&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if utilities.in_array (cite_class, whitelist.preprint_template_list ) then	-- limited parameter sets allowed for these templates&lt;br /&gt;
		state = whitelist.limited_basic_arguments[name];&lt;br /&gt;
		if true == state_test (state, name) then return true; end&lt;br /&gt;
&lt;br /&gt;
		state = whitelist.preprint_arguments[cite_class][name];					-- look in the parameter-list for the template identified by cite_class&lt;br /&gt;
		if true == state_test (state, name) then return true; end&lt;br /&gt;
&lt;br /&gt;
																				-- limited enumerated parameters list&lt;br /&gt;
		enum_name = name:gsub(&amp;quot;%d+&amp;quot;, &amp;quot;#&amp;quot; );										-- replace digit(s) with # (last25 becomes last#) (mw.ustring because non-Western 'local' digits)&lt;br /&gt;
		state = whitelist.limited_numbered_arguments[enum_name];&lt;br /&gt;
		if true == state_test (state, name) then return true; end&lt;br /&gt;
&lt;br /&gt;
		return false;															-- not supported because not found or name is set to nil&lt;br /&gt;
	end																			-- end limited parameter-set templates&lt;br /&gt;
&lt;br /&gt;
	if utilities.in_array (cite_class, whitelist.unique_param_template_list) then 	-- experiment for template-specific parameters for templates that accept parameters from the basic argument list&lt;br /&gt;
		state = whitelist.unique_arguments[cite_class][name];					-- look in the template-specific parameter-lists for the template identified by cite_class&lt;br /&gt;
		if true == state_test (state, name) then return true; end&lt;br /&gt;
	end																			-- if here, fall into general validation&lt;br /&gt;
		&lt;br /&gt;
	state = whitelist.basic_arguments[name];									-- all other templates; all normal parameters allowed&lt;br /&gt;
	if true == state_test (state, name) then return true; end&lt;br /&gt;
&lt;br /&gt;
																				-- all enumerated parameters allowed&lt;br /&gt;
	enum_name = name:gsub(&amp;quot;%d+&amp;quot;, &amp;quot;#&amp;quot; );											-- replace digit(s) with # (last25 becomes last#) (mw.ustring because non-Western 'local' digits)&lt;br /&gt;
	state = whitelist.numbered_arguments[enum_name];&lt;br /&gt;
	if true == state_test (state, name) then return true; end&lt;br /&gt;
&lt;br /&gt;
	return false;																-- not supported because not found or name is set to nil&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[=[-------------------------&amp;lt; I N T E R _ W I K I _ C H E C K &amp;gt;----------------------------------------------&lt;br /&gt;
&lt;br /&gt;
check &amp;lt;value&amp;gt; for inter-language interwiki-link markup.  &amp;lt;prefix&amp;gt; must be a MediaWiki-recognized language&lt;br /&gt;
code.  when these values have the form (without leading colon):&lt;br /&gt;
	[[&amp;lt;prefix&amp;gt;:link|label]] return label as plain-text&lt;br /&gt;
	[[&amp;lt;prefix&amp;gt;:link]] return &amp;lt;prefix&amp;gt;:link as plain-text&lt;br /&gt;
&lt;br /&gt;
return value as is else&lt;br /&gt;
&lt;br /&gt;
]=]&lt;br /&gt;
&lt;br /&gt;
local function inter_wiki_check (parameter, value)&lt;br /&gt;
	local prefix = value:match ('%[%[(%a+):');									-- get an interwiki prefix if one exists&lt;br /&gt;
	local _;&lt;br /&gt;
	&lt;br /&gt;
	if prefix and cfg.inter_wiki_map[prefix:lower()] then						-- if prefix is in the map, needs preceding colon so&lt;br /&gt;
		table.insert( z.message_tail, {utilities.set_message ('err_bad_paramlink', parameter)});	-- emit an error message&lt;br /&gt;
		_, value, _ = utilities.is_wikilink (value);							-- extract label portion from wikilink&lt;br /&gt;
	end&lt;br /&gt;
	return value;&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; M I S S I N G _ P I P E _ C H E C K &amp;gt;------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Look at the contents of a parameter. If the content has a string of characters and digits followed by an equal&lt;br /&gt;
sign, compare the alphanumeric string to the list of cs1|2 parameters.  If found, then the string is possibly a&lt;br /&gt;
parameter that is missing its pipe.  There are two tests made:&lt;br /&gt;
	{{cite ... |title=Title access-date=2016-03-17}}	-- the first parameter has a value and whitespace separates that value from the missing pipe parameter name&lt;br /&gt;
	{{cite ... |title=access-date=2016-03-17}}			-- the first parameter has no value (whitespace after the first = is trimmed by MediaWiki)&lt;br /&gt;
cs1|2 shares some parameter names with XML/HTML attributes: class=, title=, etc.  To prevent false positives XML/HTML&lt;br /&gt;
tags are removed before the search.&lt;br /&gt;
&lt;br /&gt;
If a missing pipe is detected, this function adds the missing pipe maintenance category.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function missing_pipe_check (parameter, value)&lt;br /&gt;
	local capture;&lt;br /&gt;
	value = value:gsub ('%b&amp;lt;&amp;gt;', '');											-- remove XML/HTML tags because attributes: class=, title=, etc.&lt;br /&gt;
&lt;br /&gt;
	capture = value:match ('%s+(%a[%w%-]+)%s*=') or value:match ('^(%a[%w%-]+)%s*=');	-- find and categorize parameters with possible missing pipes&lt;br /&gt;
	if capture and validate (capture) then										-- if the capture is a valid parameter name&lt;br /&gt;
		table.insert( z.message_tail, {utilities.set_message ('err_missing_pipe', parameter)});&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; H A S _ E X T R A N E O U S _ P U N C T &amp;gt;--------------------------------------&lt;br /&gt;
&lt;br /&gt;
look for extraneous terminal punctuation in most parameter values; parameters listed in skip table are not checked&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function has_extraneous_punc (param, value)&lt;br /&gt;
	if 'number' == type (param) then&lt;br /&gt;
		return;&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	param = param:gsub ('%d+', '#');											-- enumerated name-list mask params allow terminal punct; normalize &lt;br /&gt;
	if cfg.punct_skip[param] then&lt;br /&gt;
		return;																	-- parameter name found in the skip table so done&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	if value:match ('[,;:]$') then&lt;br /&gt;
		utilities.set_message ('maint_extra_punct');							-- has extraneous punctuation; add maint cat&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; C I T A T I O N &amp;gt;--------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
This is used by templates such as {{cite book}} to create the actual citation text.&lt;br /&gt;
&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
local function citation(frame)&lt;br /&gt;
	Frame = frame;																-- save a copy in case we need to display an error message in preview mode&lt;br /&gt;
	local pframe = frame:getParent()&lt;br /&gt;
	local styles;&lt;br /&gt;
	&lt;br /&gt;
	if nil ~= string.find (frame:getTitle(), 'sandbox', 1, true) then			-- did the {{#invoke:}} use sandbox version?&lt;br /&gt;
		cfg = mw.loadData ('Module:Citation/CS1/Configuration/sandbox');		-- load sandbox versions of support modules&lt;br /&gt;
		whitelist = mw.loadData ('Module:Citation/CS1/Whitelist/sandbox');&lt;br /&gt;
		utilities = require ('Module:Citation/CS1/Utilities/sandbox');&lt;br /&gt;
		validation = require ('Module:Citation/CS1/Date_validation/sandbox');&lt;br /&gt;
		identifiers = require ('Module:Citation/CS1/Identifiers/sandbox');&lt;br /&gt;
		metadata = require ('Module:Citation/CS1/COinS/sandbox');&lt;br /&gt;
		styles = 'Module:Citation/CS1/sandbox/styles.css';&lt;br /&gt;
		&lt;br /&gt;
	else																		-- otherwise&lt;br /&gt;
		cfg = mw.loadData ('Module:Citation/CS1/Configuration');				-- load live versions of support modules&lt;br /&gt;
		whitelist = mw.loadData ('Module:Citation/CS1/Whitelist');&lt;br /&gt;
		utilities = require ('Module:Citation/CS1/Utilities');&lt;br /&gt;
		validation = require ('Module:Citation/CS1/Date_validation');&lt;br /&gt;
		identifiers = require ('Module:Citation/CS1/Identifiers');&lt;br /&gt;
		metadata = require ('Module:Citation/CS1/COinS');&lt;br /&gt;
		styles = 'Module:Citation/CS1/styles.css';&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	utilities.set_selected_modules (cfg);										-- so that functions in Utilities can see the selected cfg tables&lt;br /&gt;
	identifiers.set_selected_modules (cfg, utilities);							-- so that functions in Identifiers can see the selected cfg tables and selected Utilities module&lt;br /&gt;
	validation.set_selected_modules (cfg, utilities);							-- so that functions in Date validataion can see selected cfg tables and the selected Utilities module&lt;br /&gt;
	metadata.set_selected_modules (cfg, utilities);								-- so that functions in COinS can see the selected cfg tables and selected Utilities module&lt;br /&gt;
&lt;br /&gt;
	z = utilities.z;															-- table of error and category tables in Module:Citation/CS1/Utilities&lt;br /&gt;
&lt;br /&gt;
	local args = {};															-- table where we store all of the template's arguments&lt;br /&gt;
	local suggestions = {};														-- table where we store suggestions if we need to loadData them&lt;br /&gt;
	local error_text, error_state;&lt;br /&gt;
&lt;br /&gt;
	local config = {};															-- table to store parameters from the module {{#invoke:}}&lt;br /&gt;
	for k, v in pairs( frame.args ) do											-- get parameters from the {{#invoke}} frame&lt;br /&gt;
		config[k] = v;&lt;br /&gt;
	--	args[k] = v;															-- crude debug support that allows us to render a citation from module {{#invoke:}}; skips parameter validation; TODO: keep?&lt;br /&gt;
	end	&lt;br /&gt;
&lt;br /&gt;
	local capture;																-- the single supported capture when matching unknown parameters using patterns&lt;br /&gt;
	local empty_unknowns = {};													-- sequence table to hold empty unknown params for error message listing&lt;br /&gt;
	for k, v in pairs( pframe.args ) do											-- get parameters from the parent (template) frame&lt;br /&gt;
		v = mw.ustring.gsub (v, '^%s*(.-)%s*$', '%1');							-- trim leading/trailing whitespace; when v is only whitespace, becomes empty string&lt;br /&gt;
		if v ~= '' then&lt;br /&gt;
			if ('string' == type (k)) then&lt;br /&gt;
				k = mw.ustring.gsub (k, '%d', cfg.date_names.local_digits);		-- for enumerated parameters, translate 'local' digits to Western 0-9&lt;br /&gt;
			end&lt;br /&gt;
			if not validate( k, config.CitationClass ) then			&lt;br /&gt;
				error_text = &amp;quot;&amp;quot;;&lt;br /&gt;
				if type( k ) ~= 'string' then&lt;br /&gt;
					-- exclude empty numbered parameters&lt;br /&gt;
					if v:match(&amp;quot;%S+&amp;quot;) ~= nil then&lt;br /&gt;
						error_text, error_state = utilities.set_message ( 'err_text_ignored', {v}, true );&lt;br /&gt;
					end&lt;br /&gt;
				elseif validate( k:lower(), config.CitationClass ) then &lt;br /&gt;
					error_text, error_state = utilities.set_message ( 'err_parameter_ignored_suggest', {k, k:lower()}, true );	-- suggest the lowercase version of the parameter&lt;br /&gt;
				else&lt;br /&gt;
					if nil == suggestions.suggestions then						-- if this table is nil then we need to load it&lt;br /&gt;
						if nil ~= string.find (frame:getTitle(), 'sandbox', 1, true) then			-- did the {{#invoke:}} use sandbox version?&lt;br /&gt;
							suggestions = mw.loadData( 'Module:Citation/CS1/Suggestions/sandbox' );	-- use the sandbox version&lt;br /&gt;
						else&lt;br /&gt;
							suggestions = mw.loadData( 'Module:Citation/CS1/Suggestions' );			-- use the live version&lt;br /&gt;
						end&lt;br /&gt;
					end&lt;br /&gt;
					for pattern, param in pairs (suggestions.patterns) do		-- loop through the patterns to see if we can suggest a proper parameter&lt;br /&gt;
						capture = k:match (pattern);							-- the whole match if no capture in pattern else the capture if a match&lt;br /&gt;
						if capture then											-- if the pattern matches &lt;br /&gt;
							param = utilities.substitute (param, capture);		-- add the capture to the suggested parameter (typically the enumerator)&lt;br /&gt;
							if validate (param, config.CitationClass) then		-- validate the suggestion to make sure that the suggestion is supported by this template (necessary for limited parameter lists)&lt;br /&gt;
								error_text, error_state = utilities.set_message ('err_parameter_ignored_suggest', {k, param}, true);	-- set the suggestion error message&lt;br /&gt;
							else&lt;br /&gt;
								error_text, error_state = utilities.set_message ( 'err_parameter_ignored', {param}, true );	-- suggested param not supported by this template&lt;br /&gt;
								v = '';											-- unset&lt;br /&gt;
							end&lt;br /&gt;
						end&lt;br /&gt;
					end&lt;br /&gt;
					if not utilities.is_set (error_text) then					-- couldn't match with a pattern, is there an expicit suggestion?&lt;br /&gt;
						if suggestions.suggestions[ k:lower() ] ~= nil then&lt;br /&gt;
							error_text, error_state = utilities.set_message ( 'err_parameter_ignored_suggest', {k, suggestions.suggestions[ k:lower() ]}, true );&lt;br /&gt;
						else&lt;br /&gt;
							error_text, error_state = utilities.set_message ( 'err_parameter_ignored', {k}, true );&lt;br /&gt;
							v = '';												-- unset value assigned to unrecognized parameters (this for the limited parameter lists)&lt;br /&gt;
						end&lt;br /&gt;
					end&lt;br /&gt;
				end				  &lt;br /&gt;
				if error_text ~= '' then&lt;br /&gt;
					table.insert( z.message_tail, {error_text, error_state} );&lt;br /&gt;
				end				&lt;br /&gt;
			end&lt;br /&gt;
&lt;br /&gt;
			args[k] = v;														-- save this parameter and its value&lt;br /&gt;
&lt;br /&gt;
		elseif not utilities.is_set (v) then									-- for empty parameters&lt;br /&gt;
			if not validate (k, config.CitationClass, true) then				-- is this empty parameter a valid parameter&lt;br /&gt;
				k = ('' == k) and '(empty string)' or k;						-- when k is empty string (or was space(s) trimmed to empty string), replace with descriptive text&lt;br /&gt;
				table.insert (empty_unknowns, utilities.wrap_style ('parameter', k));	-- format for error message and add to the list&lt;br /&gt;
			end&lt;br /&gt;
																				-- crude debug support that allows us to render a citation from module {{#invoke:}} TODO: keep?&lt;br /&gt;
	--	elseif args[k] ~= nil or (k == 'postscript') then						-- when args[k] has a value from {{#invoke}} frame (we don't normally do that)&lt;br /&gt;
	--		args[k] = v;														-- overwrite args[k] with empty string from pframe.args[k] (template frame); v is empty string here&lt;br /&gt;
		end																		-- not sure about the postscript bit; that gets handled in parameter validation; historical artifact?&lt;br /&gt;
	end	&lt;br /&gt;
&lt;br /&gt;
	if 0 ~= #empty_unknowns then												-- create empty unknown error message&lt;br /&gt;
		table.insert (z.message_tail, {utilities.set_message ('err_param_unknown_empty', {&lt;br /&gt;
			1 == #empty_unknowns and '' or 's',&lt;br /&gt;
			utilities.make_sep_list (#empty_unknowns, empty_unknowns)&lt;br /&gt;
			}, true )});&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	for k, v in pairs( args ) do&lt;br /&gt;
		if 'string' == type (k) then											-- don't evaluate positional parameters&lt;br /&gt;
			has_invisible_chars (k, v);											-- look for invisible characters&lt;br /&gt;
		end&lt;br /&gt;
		has_extraneous_punc (k, v);												-- look for extraneous terminal punctuation in parameter values&lt;br /&gt;
		missing_pipe_check (k, v);												-- do we think that there is a parameter that is missing a pipe?&lt;br /&gt;
		args[k] = inter_wiki_check (k, v);										-- when language interwiki-linked parameter missing leading colon replace with wiki-link label&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	return table.concat ({citation0( config, args), frame:extensionTag ('templatestyles', '', {src=styles})});&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
--[[--------------------------&amp;lt; E X P O R T E D   F U N C T I O N S &amp;gt;------------------------------------------&lt;br /&gt;
]]&lt;br /&gt;
&lt;br /&gt;
return {citation = citation};&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Module:Redirect_template&amp;diff=617</id>
		<title>Module:Redirect template</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Module:Redirect_template&amp;diff=617"/>
		<updated>2020-10-29T00:13:43Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: 1 revision imported&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;require('Module:No globals')&lt;br /&gt;
&lt;br /&gt;
local p = {}&lt;br /&gt;
&lt;br /&gt;
-- key is beginning of arg name. value is table with namespace number and link&lt;br /&gt;
-- alternatively, a function taking the namespace number and returning a validity&lt;br /&gt;
-- can be used&lt;br /&gt;
local namespaceCategories = {&lt;br /&gt;
	all = { function() return true end },&lt;br /&gt;
	main = { 0, '[[wp:mainspace|main]]' },&lt;br /&gt;
	help = { 12, '[[wp:help namespace|help]]' },&lt;br /&gt;
	portal = { 100, '[[wp:portal|portal]]' },&lt;br /&gt;
	talk = { function(n) return n &amp;gt; 0 and n%2 == 1 end, '[[Help:Using talk pages|talk]]' },&lt;br /&gt;
	template = { 10, '[[wp:template namespace|template]]' },&lt;br /&gt;
	wikipedia = { 4, '[[wp:project namespace|Wikipedia project]]' },&lt;br /&gt;
	category = { 14, '[[wp:categorization|category]]' },&lt;br /&gt;
	user = { 2, '[[wp:user pages|user]]' },&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
-- remove whitespaces from beginning and end of args&lt;br /&gt;
local function valueFunc(key, val)&lt;br /&gt;
	if type(val) == 'string' then&lt;br /&gt;
		val = val:match('^%s*(.-)%s*$')&lt;br /&gt;
		if val == '' then&lt;br /&gt;
			return nil&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	return val&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
local function getPrettyName(args)&lt;br /&gt;
	for k in pairs(namespaceCategories) do&lt;br /&gt;
		if args[k .. ' category'] then&lt;br /&gt;
			return string.format(&amp;quot;'''[[:Category:%s|%s]]''': &amp;quot;, args[k .. ' category'], args.name)&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	return string.format(&amp;quot;'''%s''': &amp;quot;, args.name)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p.main(frame)&lt;br /&gt;
	local args = require('Module:Arguments').getArgs(frame, {wrappers = 'Template:Redirect template', valueFunc = valueFunc})&lt;br /&gt;
	local namespace = mw.title.getCurrentTitle().namespace&lt;br /&gt;
&lt;br /&gt;
	--- XXX: this is a HORRIBLE HACK. kill it with fire as soon as https://bugzilla.wikimedia.org/show_bug.cgi?id=12974 is fixed&lt;br /&gt;
	local beCompatibleWithBug12974 = args.info and (args.info:find('^[:;#*]', 1) == 1 or args.info:find('{|', 1, true) == 1) and '\n' or ' '&lt;br /&gt;
	&lt;br /&gt;
	local content = string.format('\n&amp;lt;div class=&amp;quot;rcat %s&amp;quot;&amp;gt;\n*%sThis is a redirect%s%s.%s%s\n&amp;lt;/div&amp;gt;',&lt;br /&gt;
		args.class or '',&lt;br /&gt;
		args.name and getPrettyName(args) or '',&lt;br /&gt;
		args.from and (' from ' .. args.from) or '',&lt;br /&gt;
		args.to and (' to ' .. args.to) or '',&lt;br /&gt;
		args.info and beCompatibleWithBug12974 or '',&lt;br /&gt;
		args.info or ''&lt;br /&gt;
	)&lt;br /&gt;
	&lt;br /&gt;
	for k,v in pairs(namespaceCategories) do&lt;br /&gt;
		if args[k .. ' category'] then&lt;br /&gt;
			if type(v[1]) == 'function' and v[1](namespace) or v[1] == namespace then&lt;br /&gt;
				content = content .. string.format('[[Category:%s]]', args[k .. ' category'])&lt;br /&gt;
			elseif args['other category'] then&lt;br /&gt;
				content = content .. string.format('[[Category:%s]]', args['other category'])&lt;br /&gt;
			else&lt;br /&gt;
				content = content .. frame:expandTemplate{title = 'Incorrect redirect template', args = {v[2]}}&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if namespace == 0 then&lt;br /&gt;
		local yesno = require('Module:Yesno')&lt;br /&gt;
		if yesno(args.printworthy) == true then&lt;br /&gt;
			return content .. '[[Category:Printworthy redirects]]'&lt;br /&gt;
		elseif yesno(args.printworthy) == false then&lt;br /&gt;
			return content .. '[[Category:Unprintworthy redirects]]'&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	return content&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
return p&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Module:Parameter_names_example&amp;diff=607</id>
		<title>Module:Parameter names example</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Module:Parameter_names_example&amp;diff=607"/>
		<updated>2020-10-29T00:13:42Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: 1 revision imported&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;-- This module implements {{parameter names example}}.&lt;br /&gt;
&lt;br /&gt;
local p = {}&lt;br /&gt;
&lt;br /&gt;
local function makeParam(s)&lt;br /&gt;
	local lb = '&amp;amp;#123;'&lt;br /&gt;
	local rb = '&amp;amp;#125;'&lt;br /&gt;
	return lb:rep(3) .. s .. rb:rep(3)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
local function italicize(s)&lt;br /&gt;
	return &amp;quot;''&amp;quot; .. s .. &amp;quot;''&amp;quot;&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
local function plain(s)&lt;br /&gt;
	return s&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p._main(args, frame)&lt;br /&gt;
	-- Find how we want to format the arguments to the template.&lt;br /&gt;
	local formatFunc&lt;br /&gt;
	if args._display == 'italics' or args._display == 'italic' then&lt;br /&gt;
		formatFunc = italicize&lt;br /&gt;
	elseif args._display == 'plain' then&lt;br /&gt;
		formatFunc = plain&lt;br /&gt;
	else&lt;br /&gt;
		formatFunc = makeParam&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Build the table of template arguments.&lt;br /&gt;
	local targs = {}&lt;br /&gt;
	for k, v in pairs(args) do&lt;br /&gt;
		if type(k) == 'number' then&lt;br /&gt;
			targs[v] = formatFunc(v)&lt;br /&gt;
		elseif not k:find('^_') then&lt;br /&gt;
			targs[k] = v&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	targs['nocat'] = 'yes';&lt;br /&gt;
	targs['categories'] = 'no';&lt;br /&gt;
	targs['demo'] = 'yes';&lt;br /&gt;
&lt;br /&gt;
	-- Find the template name.&lt;br /&gt;
	local template&lt;br /&gt;
	if args._template then&lt;br /&gt;
		template = args._template&lt;br /&gt;
	else&lt;br /&gt;
		local currentTitle = mw.title.getCurrentTitle()&lt;br /&gt;
		if currentTitle.prefixedText:find('/sandbox$') then&lt;br /&gt;
			template = currentTitle.prefixedText&lt;br /&gt;
		else&lt;br /&gt;
			template = currentTitle.basePageTitle.prefixedText&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Call the template with the arguments.&lt;br /&gt;
	frame = frame or mw.getCurrentFrame()&lt;br /&gt;
	local success, result = pcall(&lt;br /&gt;
		frame.expandTemplate,&lt;br /&gt;
		frame,&lt;br /&gt;
		{title = template, args = targs}&lt;br /&gt;
	)&lt;br /&gt;
	if success then&lt;br /&gt;
		return result&lt;br /&gt;
	else&lt;br /&gt;
		return ''&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p.main(frame)&lt;br /&gt;
	local args = require('Module:Arguments').getArgs(frame, {&lt;br /&gt;
		wrappers = 'Template:Parameter names example'&lt;br /&gt;
	})&lt;br /&gt;
	return p._main(args, frame)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
return p&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
	<entry>
		<id>https://alpha.wikianesthesia.org/w/index.php?title=Module:Hatnote_list&amp;diff=605</id>
		<title>Module:Hatnote list</title>
		<link rel="alternate" type="text/html" href="https://alpha.wikianesthesia.org/w/index.php?title=Module:Hatnote_list&amp;diff=605"/>
		<updated>2020-10-29T00:13:42Z</updated>

		<summary type="html">&lt;p&gt;WikiAnesthesia: 1 revision imported&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;--------------------------------------------------------------------------------&lt;br /&gt;
--                           Module:Hatnote list                              --&lt;br /&gt;
--                                                                            --&lt;br /&gt;
-- This module produces and formats lists for use in hatnotes. In particular, --&lt;br /&gt;
-- it implements the for-see list, i.e. lists of &amp;quot;For X, see Y&amp;quot; statements,   --&lt;br /&gt;
-- as used in {{about}}, {{redirect}}, and their variants. Also introduced    --&lt;br /&gt;
-- are andList &amp;amp; orList helpers for formatting lists with those conjunctions. --&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
local mArguments --initialize lazily&lt;br /&gt;
local mHatnote = require('Module:Hatnote')&lt;br /&gt;
local libraryUtil = require('libraryUtil')&lt;br /&gt;
local checkType = libraryUtil.checkType&lt;br /&gt;
local p = {}&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
-- List stringification helper functions&lt;br /&gt;
--&lt;br /&gt;
-- These functions are used for stringifying lists, usually page lists inside&lt;br /&gt;
-- the &amp;quot;Y&amp;quot; portion of &amp;quot;For X, see Y&amp;quot; for-see items.&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
--default options table used across the list stringification functions&lt;br /&gt;
local stringifyListDefaultOptions = {&lt;br /&gt;
	conjunction = &amp;quot;and&amp;quot;,&lt;br /&gt;
	separator = &amp;quot;,&amp;quot;,&lt;br /&gt;
	altSeparator = &amp;quot;;&amp;quot;,&lt;br /&gt;
	space = &amp;quot; &amp;quot;,&lt;br /&gt;
	formatted = false&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
-- Stringifies a list generically; probably shouldn't be used directly&lt;br /&gt;
function stringifyList(list, options)&lt;br /&gt;
	-- Type-checks, defaults, and a shortcut&lt;br /&gt;
	checkType(&amp;quot;stringifyList&amp;quot;, 1, list, &amp;quot;table&amp;quot;)&lt;br /&gt;
	if #list == 0 then return nil end&lt;br /&gt;
	checkType(&amp;quot;stringifyList&amp;quot;, 2, options, &amp;quot;table&amp;quot;, true)&lt;br /&gt;
	options = options or {}&lt;br /&gt;
	for k, v in pairs(stringifyListDefaultOptions) do&lt;br /&gt;
		if options[k] == nil then options[k] = v end&lt;br /&gt;
	end&lt;br /&gt;
	local s = options.space&lt;br /&gt;
	-- Format the list if requested&lt;br /&gt;
	if options.formatted then list = mHatnote.formatPages(unpack(list)) end&lt;br /&gt;
	-- Set the separator; if any item contains it, use the alternate separator&lt;br /&gt;
	local separator = options.separator&lt;br /&gt;
	--searches display text only&lt;br /&gt;
	local function searchDisp(t, f)&lt;br /&gt;
		return string.find(string.sub(t, (string.find(t, '|') or 0) + 1), f)&lt;br /&gt;
	end&lt;br /&gt;
	for k, v in pairs(list) do&lt;br /&gt;
		if searchDisp(v, separator) then&lt;br /&gt;
			separator = options.altSeparator&lt;br /&gt;
			break&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	-- Set the conjunction, apply Oxford comma, and force a comma if #1 has &amp;quot;§&amp;quot;&lt;br /&gt;
	local conjunction = s .. options.conjunction .. s&lt;br /&gt;
	if #list == 2 and searchDisp(list[1], &amp;quot;§&amp;quot;) or #list &amp;gt; 2 then&lt;br /&gt;
		conjunction = separator .. conjunction&lt;br /&gt;
	end&lt;br /&gt;
	-- Return the formatted string&lt;br /&gt;
	return mw.text.listToText(list, separator .. s, conjunction)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
--DRY function&lt;br /&gt;
function conjList (conj, list, fmt)&lt;br /&gt;
	return stringifyList(list, {conjunction = conj, formatted = fmt})&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
-- Stringifies lists with &amp;quot;and&amp;quot; or &amp;quot;or&amp;quot;&lt;br /&gt;
function p.andList (...) return conjList(&amp;quot;and&amp;quot;, ...) end&lt;br /&gt;
function p.orList (...) return conjList(&amp;quot;or&amp;quot;, ...) end&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
-- For see&lt;br /&gt;
--&lt;br /&gt;
-- Makes a &amp;quot;For X, see [[Y]].&amp;quot; list from raw parameters. Intended for the&lt;br /&gt;
-- {{about}} and {{redirect}} templates and their variants.&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
--default options table used across the forSee family of functions&lt;br /&gt;
local forSeeDefaultOptions = {&lt;br /&gt;
	andKeyword = 'and',&lt;br /&gt;
	title = mw.title.getCurrentTitle().text,&lt;br /&gt;
	otherText = 'other uses',&lt;br /&gt;
	forSeeForm = 'For %s, see %s.',&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
--Collapses duplicate punctuation&lt;br /&gt;
function punctuationCollapse (text)&lt;br /&gt;
	local replacements = {&lt;br /&gt;
		[&amp;quot;%.%.$&amp;quot;] = &amp;quot;.&amp;quot;,&lt;br /&gt;
		[&amp;quot;%?%.$&amp;quot;] = &amp;quot;?&amp;quot;,&lt;br /&gt;
		[&amp;quot;%!%.$&amp;quot;] = &amp;quot;!&amp;quot;,&lt;br /&gt;
		[&amp;quot;%.%]%]%.$&amp;quot;] = &amp;quot;.]]&amp;quot;,&lt;br /&gt;
		[&amp;quot;%?%]%]%.$&amp;quot;] = &amp;quot;?]]&amp;quot;,&lt;br /&gt;
		[&amp;quot;%!%]%]%.$&amp;quot;] = &amp;quot;!]]&amp;quot;&lt;br /&gt;
	}&lt;br /&gt;
	for k, v in pairs(replacements) do text = string.gsub(text, k, v) end&lt;br /&gt;
	return text&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
-- Structures arguments into a table for stringification, &amp;amp; options&lt;br /&gt;
function p.forSeeArgsToTable (args, from, options)&lt;br /&gt;
	-- Type-checks and defaults&lt;br /&gt;
	checkType(&amp;quot;forSeeArgsToTable&amp;quot;, 1, args, 'table')&lt;br /&gt;
	checkType(&amp;quot;forSeeArgsToTable&amp;quot;, 2, from, 'number', true)&lt;br /&gt;
	from = from or 1&lt;br /&gt;
	checkType(&amp;quot;forSeeArgsToTable&amp;quot;, 3, options, 'table', true)&lt;br /&gt;
	options = options or {}&lt;br /&gt;
	for k, v in pairs(forSeeDefaultOptions) do&lt;br /&gt;
		if options[k] == nil then options[k] = v end&lt;br /&gt;
	end&lt;br /&gt;
	-- maxArg's gotten manually because getArgs() and table.maxn aren't friends&lt;br /&gt;
	local maxArg = 0&lt;br /&gt;
	for k, v in pairs(args) do&lt;br /&gt;
		if type(k) == 'number' and k &amp;gt; maxArg then maxArg = k end&lt;br /&gt;
	end&lt;br /&gt;
	-- Structure the data out from the parameter list:&lt;br /&gt;
	-- * forTable is the wrapper table, with forRow rows&lt;br /&gt;
	-- * Rows are tables of a &amp;quot;use&amp;quot; string &amp;amp; a &amp;quot;pages&amp;quot; table of pagename strings&lt;br /&gt;
	-- * Blanks are left empty for defaulting elsewhere, but can terminate list&lt;br /&gt;
	local forTable = {}&lt;br /&gt;
	local i = from&lt;br /&gt;
	local terminated = false&lt;br /&gt;
	-- If there is extra text, and no arguments are given, give nil value&lt;br /&gt;
	-- to not produce default of &amp;quot;For other uses, see foo (disambiguation)&amp;quot;&lt;br /&gt;
	if options.extratext and i &amp;gt; maxArg then return nil end&lt;br /&gt;
	-- Loop to generate rows&lt;br /&gt;
	repeat&lt;br /&gt;
		-- New empty row&lt;br /&gt;
		local forRow = {}&lt;br /&gt;
		-- On blank use, assume list's ended &amp;amp; break at end of this loop&lt;br /&gt;
		forRow.use = args[i]&lt;br /&gt;
		if not args[i] then terminated = true end&lt;br /&gt;
		-- New empty list of pages&lt;br /&gt;
		forRow.pages = {}&lt;br /&gt;
		-- Insert first pages item if present&lt;br /&gt;
		table.insert(forRow.pages, args[i + 1])&lt;br /&gt;
		-- If the param after next is &amp;quot;and&amp;quot;, do inner loop to collect params&lt;br /&gt;
		-- until the &amp;quot;and&amp;quot;'s stop. Blanks are ignored: &amp;quot;1|and||and|3&amp;quot; → {1, 3}&lt;br /&gt;
		while args[i + 2] == options.andKeyword do&lt;br /&gt;
			if args[i + 3] then &lt;br /&gt;
				table.insert(forRow.pages, args[i + 3])&lt;br /&gt;
			end&lt;br /&gt;
			-- Increment to next &amp;quot;and&amp;quot;&lt;br /&gt;
			i = i + 2&lt;br /&gt;
		end&lt;br /&gt;
		-- Increment to next use&lt;br /&gt;
		i = i + 2&lt;br /&gt;
		-- Append the row&lt;br /&gt;
		table.insert(forTable, forRow)&lt;br /&gt;
	until terminated or i &amp;gt; maxArg&lt;br /&gt;
	&lt;br /&gt;
	return forTable&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
-- Stringifies a table as formatted by forSeeArgsToTable&lt;br /&gt;
function p.forSeeTableToString (forSeeTable, options)&lt;br /&gt;
	-- Type-checks and defaults&lt;br /&gt;
	checkType(&amp;quot;forSeeTableToString&amp;quot;, 1, forSeeTable, &amp;quot;table&amp;quot;, true)&lt;br /&gt;
	checkType(&amp;quot;forSeeTableToString&amp;quot;, 2, options, &amp;quot;table&amp;quot;, true)&lt;br /&gt;
	options = options or {}&lt;br /&gt;
	for k, v in pairs(forSeeDefaultOptions) do&lt;br /&gt;
		if options[k] == nil then options[k] = v end&lt;br /&gt;
	end&lt;br /&gt;
	-- Stringify each for-see item into a list&lt;br /&gt;
	local strList = {}&lt;br /&gt;
	if forSeeTable then&lt;br /&gt;
		for k, v in pairs(forSeeTable) do&lt;br /&gt;
			local useStr = v.use or options.otherText&lt;br /&gt;
			local pagesStr = p.andList(v.pages, true) or mHatnote._formatLink{link = mHatnote.disambiguate(options.title)}&lt;br /&gt;
			local forSeeStr = string.format(options.forSeeForm, useStr, pagesStr)&lt;br /&gt;
			forSeeStr = punctuationCollapse(forSeeStr)&lt;br /&gt;
			table.insert(strList, forSeeStr)&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	if options.extratext then table.insert(strList, punctuationCollapse(options.extratext..'.')) end&lt;br /&gt;
	-- Return the concatenated list&lt;br /&gt;
	return table.concat(strList, ' ')&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
-- Produces a &amp;quot;For X, see [[Y]]&amp;quot; string from arguments. Expects index gaps&lt;br /&gt;
-- but not blank/whitespace values. Ignores named args and args &amp;lt; &amp;quot;from&amp;quot;.&lt;br /&gt;
function p._forSee (args, from, options)&lt;br /&gt;
	local forSeeTable = p.forSeeArgsToTable(args, from, options)&lt;br /&gt;
	return p.forSeeTableToString(forSeeTable, options)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
-- As _forSee, but uses the frame.&lt;br /&gt;
function p.forSee (frame, from, options)&lt;br /&gt;
	mArguments = require('Module:Arguments')&lt;br /&gt;
	return p._forSee(mArguments.getArgs(frame), from, options)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
return p&lt;/div&gt;</summary>
		<author><name>WikiAnesthesia</name></author>
	</entry>
</feed>