<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en-GB">
	<id>https://stockhub.co/index.php?action=history&amp;feed=atom&amp;title=Module%3AJct%2Fcity</id>
	<title>Module:Jct/city - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://stockhub.co/index.php?action=history&amp;feed=atom&amp;title=Module%3AJct%2Fcity"/>
	<link rel="alternate" type="text/html" href="https://stockhub.co/index.php?title=Module:Jct/city&amp;action=history"/>
	<updated>2026-04-18T21:12:27Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.43.5</generator>
	<entry>
		<id>https://stockhub.co/index.php?title=Module:Jct/city&amp;diff=137085&amp;oldid=prev</id>
		<title>imported&gt;Fredddie: rm space as there already is one</title>
		<link rel="alternate" type="text/html" href="https://stockhub.co/index.php?title=Module:Jct/city&amp;diff=137085&amp;oldid=prev"/>
		<updated>2021-08-18T13:00:34Z</updated>

		<summary type="html">&lt;p&gt;rm space as there already is one&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;local p = {}&lt;br /&gt;
&lt;br /&gt;
local concat = table.concat&lt;br /&gt;
local insert = table.insert&lt;br /&gt;
&lt;br /&gt;
local state&lt;br /&gt;
&lt;br /&gt;
local function stateName(args)&lt;br /&gt;
	local AUSabbrs = {NT = &amp;quot;Northern Territory&amp;quot;, WA = &amp;quot;Western Australia&amp;quot;}&lt;br /&gt;
	&lt;br /&gt;
	local data = mw.loadData(&amp;quot;Module:Jct/statename&amp;quot;)&lt;br /&gt;
	local abbr = args.state or args.province&lt;br /&gt;
	local country = args.country&lt;br /&gt;
	if country == &amp;#039;AUS&amp;#039; then&lt;br /&gt;
		return AUSabbrs[abbr] or data[abbr]&lt;br /&gt;
	else&lt;br /&gt;
		return data[abbr]&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
local function location(args, num)&lt;br /&gt;
	local city = args[&amp;quot;city&amp;quot; .. num]&lt;br /&gt;
	local location = args[&amp;quot;location&amp;quot; .. num]&lt;br /&gt;
	local areadab = args[&amp;quot;areadab&amp;quot; .. num]&lt;br /&gt;
	local countydab = args[&amp;quot;countydab&amp;quot; .. num]&lt;br /&gt;
	&lt;br /&gt;
	if not(city or location) then&lt;br /&gt;
		return &amp;#039;&amp;#039;&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	local parts&lt;br /&gt;
	if num == 1 then&lt;br /&gt;
		parts = {&amp;quot;– &amp;quot;}&lt;br /&gt;
	else&lt;br /&gt;
		parts = {&amp;quot;, &amp;quot;}&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	if location then&lt;br /&gt;
		insert(parts, location)&lt;br /&gt;
		return concat(parts)&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	insert(parts, &amp;quot;[[&amp;quot; .. city)&lt;br /&gt;
	if areadab then&lt;br /&gt;
		insert(parts, &amp;quot; (&amp;quot; .. areadab .. &amp;quot;)&amp;quot;)&lt;br /&gt;
	end&lt;br /&gt;
	if countydab then&lt;br /&gt;
		insert(parts, &amp;quot;, &amp;quot; .. countydab .. &amp;quot; County&amp;quot;)&lt;br /&gt;
	end&lt;br /&gt;
	if state then&lt;br /&gt;
		insert(parts, &amp;quot;, &amp;quot; .. state)&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	insert(parts, &amp;quot;|&amp;quot; .. city .. &amp;quot;]]&amp;quot;)&lt;br /&gt;
	return concat(parts)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p.city(args)&lt;br /&gt;
	state = stateName(args)&lt;br /&gt;
	local cities = {}&lt;br /&gt;
	local locationCount = 1&lt;br /&gt;
	repeat&lt;br /&gt;
		local location = location(args, locationCount)&lt;br /&gt;
		insert(cities, location)&lt;br /&gt;
		local empty = (location == &amp;#039;&amp;#039;)&lt;br /&gt;
		locationCount = locationCount + 1&lt;br /&gt;
	until empty&lt;br /&gt;
	return concat(cities)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
return p&lt;/div&gt;</summary>
		<author><name>imported&gt;Fredddie</name></author>
	</entry>
</feed>