<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://pool.calebcooper.ie/index.php?action=history&amp;feed=atom&amp;title=Module%3ACoordinates%2Fdoc</id>
	<title>Module:Coordinates/doc - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://pool.calebcooper.ie/index.php?action=history&amp;feed=atom&amp;title=Module%3ACoordinates%2Fdoc"/>
	<link rel="alternate" type="text/html" href="https://pool.calebcooper.ie/index.php?title=Module:Coordinates/doc&amp;action=history"/>
	<updated>2026-04-08T00:09:50Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.43.8</generator>
	<entry>
		<id>https://pool.calebcooper.ie/index.php?title=Module:Coordinates/doc&amp;diff=15513&amp;oldid=prev</id>
		<title>Caleb Cooper: Created page with &quot;{{High-risk}} {{Module rating|protected}} {{Intricate template}} {{Commons Import}} &#039;&#039;&#039;Note:&#039;&#039;&#039; The code which this module&#039;s main function (&lt;code&gt;coord&lt;/code&gt;) outputs is dire...&quot;</title>
		<link rel="alternate" type="text/html" href="https://pool.calebcooper.ie/index.php?title=Module:Coordinates/doc&amp;diff=15513&amp;oldid=prev"/>
		<updated>2020-11-07T10:52:40Z</updated>

		<summary type="html">&lt;p&gt;Created page with &amp;quot;{{High-risk}} {{Module rating|protected}} {{Intricate template}} {{Commons Import}} &amp;#039;&amp;#039;&amp;#039;Note:&amp;#039;&amp;#039;&amp;#039; The code which this module&amp;#039;s main function (&amp;lt;code&amp;gt;coord&amp;lt;/code&amp;gt;) outputs is dire...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;{{High-risk}}&lt;br /&gt;
{{Module rating|protected}}&lt;br /&gt;
{{Intricate template}}&lt;br /&gt;
{{Commons Import}}&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Note:&amp;#039;&amp;#039;&amp;#039; The code which this module&amp;#039;s main function (&amp;lt;code&amp;gt;coord&amp;lt;/code&amp;gt;) outputs is directly parsed and/or manipulated by [[Module:Location map]] and other functions of this module itself (&amp;lt;code&amp;gt;coord2text&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;coordinsert&amp;lt;/code&amp;gt;). If the structure of the output changes (for example, to use [[:mw:Help:Extension:Kartographer|the &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;&amp;lt;mapframe&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;&amp;lt;maplink&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt; tags]]), please update the aforementioned scripts as well.&lt;br /&gt;
&lt;br /&gt;
==Using the module with coordinsert==&lt;br /&gt;
When using the {{tl|Coord}} template inside another template, like an infobox, there may be parameters (like &amp;lt;code&amp;gt;&amp;lt;var&amp;gt;type&amp;lt;/var&amp;gt;:&amp;lt;var&amp;gt;airport&amp;lt;/var&amp;gt;&amp;lt;/code&amp;gt;) which should be added automatically. To do so, do something like this:&lt;br /&gt;
 &amp;lt;code&amp;gt;&amp;amp;#123;&amp;amp;#123;#if:&amp;amp;#123;&amp;amp;#123;&amp;amp;#123;coordinates&amp;amp;#124;&amp;amp;#125;&amp;amp;#125;&amp;amp;#125;&amp;amp;#124;&amp;amp;#123;&amp;amp;#123;#invoke:Coordinates&amp;amp;#124;coordinsert&amp;amp;#124;&amp;amp;#123;&amp;amp;#123;&amp;amp;#123;coordinates&amp;amp;#124;&amp;amp;#125;&amp;amp;#125;&amp;amp;#125;&amp;amp;#124;&amp;lt;var&amp;gt;parameter1:value1&amp;amp;#124;parameter2:value2&amp;amp;#124;parameter3:value3…&amp;lt;/var&amp;gt;&amp;amp;#125;&amp;amp;#125;&amp;amp;#124;&amp;lt;/code&amp;gt; &lt;br /&gt;
&lt;br /&gt;
Do not add more vertical bars &amp;lt;code&amp;gt;&amp;amp;#124;&amp;lt;/code&amp;gt; than necessary. &lt;br /&gt;
&lt;br /&gt;
==Using the module with coord2text to extract latitude or longitude== &lt;br /&gt;
Developers maintaining legacy code may need to extract latitude or longitude to use a parameters in other code, or a mathematical expression. &lt;br /&gt;
The module&amp;#039;s &amp;quot;coord2text&amp;quot; function can be used to extract data from the {{tl|Coord}} template. To extract the latitude from a Coord template, use:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;{{#invoke:coordinates|coord2text|{{Coord|57|18|22|N|4|27|32|E}}|lat}}&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt; &amp;amp;rarr; {{#invoke:coordinates|coord2text|{{Coord|57|18|22|N|4|27|32|E}}|lat}} &lt;br /&gt;
&lt;br /&gt;
To extract the longitude, use: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;{{#invoke:coordinates|coord2text|{{Coord|57|18|22|N|4|27|32|E}}|long}}&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt; &amp;amp;rarr; {{#invoke:coordinates|coord2text|{{Coord|57|18|22|N|4|27|32|E}}|long}}&lt;br /&gt;
&lt;br /&gt;
== Modules using this module directly ==&lt;br /&gt;
* [[Module:HS listed building row]]&lt;br /&gt;
&lt;br /&gt;
== Tracking categories ==&lt;br /&gt;
* {{clc|Pages with malformed coordinate tags}}&lt;br /&gt;
* {{clc|Coordinates not on Wikidata‎}}&lt;br /&gt;
* {{clc|Coordinates on Wikidata‎}}&lt;br /&gt;
* {{clc|Coordinates on Wikidata set to no value‎}}&lt;br /&gt;
* {{clc|Coordinates on Wikidata set to unknown value‎}}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;includeonly&amp;gt;{{#switch:{{SUBPAGENAME}}|sandbox2|sandbox=|&lt;br /&gt;
[[Category:Modules that add a tracking category]]&lt;br /&gt;
}}&amp;lt;/includeonly&amp;gt;&lt;/div&gt;</summary>
		<author><name>Caleb Cooper</name></author>
	</entry>
</feed>