<?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%3AOdot_control</id>
	<title>Module:Odot control - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://stockhub.co/index.php?action=history&amp;feed=atom&amp;title=Module%3AOdot_control"/>
	<link rel="alternate" type="text/html" href="https://stockhub.co/index.php?title=Module:Odot_control&amp;action=history"/>
	<updated>2026-06-07T16:17:26Z</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:Odot_control&amp;diff=144161&amp;oldid=prev</id>
		<title>imported&gt;Happy5214: Reconfiguring URLs to account for changed format of 2012-13 PDF links</title>
		<link rel="alternate" type="text/html" href="https://stockhub.co/index.php?title=Module:Odot_control&amp;diff=144161&amp;oldid=prev"/>
		<updated>2013-12-12T08:59:41Z</updated>

		<summary type="html">&lt;p&gt;Reconfiguring URLs to account for changed format of 2012-13 PDF links&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;local p = { } --Package to be exported&lt;br /&gt;
&lt;br /&gt;
local function countyNumber(county)&lt;br /&gt;
	local numbers = mw.loadData(&amp;quot;Module:Odot control/counties&amp;quot;)&lt;br /&gt;
	return numbers[county]&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p.url(frame)&lt;br /&gt;
	--This function builds URLs.&lt;br /&gt;
	local pframe = frame:getParent() --get arguments passed to the template&lt;br /&gt;
	local args = pframe.args&lt;br /&gt;
	local county = args[&amp;#039;county&amp;#039;] or &amp;#039;&amp;#039; --this string holds the raw county name&lt;br /&gt;
	local countyProcessed --this string holds the processed county name to be added to the URL&lt;br /&gt;
	&lt;br /&gt;
	--Le Flore and Roger Mills need special treatment to handle the spaces.&lt;br /&gt;
	--Everything else just gets converted to lower case.&lt;br /&gt;
	if county == &amp;quot;Le Flore&amp;quot; then&lt;br /&gt;
		countyProcessed = &amp;quot;leflore&amp;quot;&lt;br /&gt;
	elseif county == &amp;quot;Roger Mills&amp;quot; then&lt;br /&gt;
		countyProcessed = &amp;quot;rogermills&amp;quot;&lt;br /&gt;
	else&lt;br /&gt;
		countyProcessed = county:lower()&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	local edition = p.edition(frame)&lt;br /&gt;
	if edition == &amp;quot;2012–2013&amp;quot; then&lt;br /&gt;
		local countyNumber = countyNumber(county)&lt;br /&gt;
		return &amp;quot;http://www.odot.org/maps/control-section/2012/map_csect_2012-&amp;quot; .. countyNumber .. &amp;#039;-&amp;#039; .. countyProcessed .. &amp;quot;.pdf&amp;quot;&lt;br /&gt;
	else&lt;br /&gt;
		return &amp;quot;http://www.odot.org/hqdiv/p-r-div/maps/control-maps/&amp;quot; .. countyProcessed .. &amp;quot;.pdf&amp;quot;&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p.edition(frame)&lt;br /&gt;
	--This function fills in the edition field of cite map.&lt;br /&gt;
	local pframe = frame:getParent() --get arguments passed to the template&lt;br /&gt;
	local args = pframe.args&lt;br /&gt;
	local year = args[&amp;#039;year&amp;#039;] or &amp;#039;&amp;#039;&lt;br /&gt;
	&lt;br /&gt;
	local editions = {[&amp;quot;2004&amp;quot;] = &amp;quot;2004&amp;quot;, [&amp;quot;2006&amp;quot;] = &amp;quot;2006&amp;quot;, [&amp;quot;2008&amp;quot;] = &amp;quot;2008&amp;quot;,&lt;br /&gt;
	                  [&amp;quot;2010&amp;quot;] = &amp;quot;2010–2011&amp;quot;, [&amp;quot;2011&amp;quot;] = &amp;quot;2010–2011&amp;quot;, [&amp;quot;2010–2011&amp;quot;] = &amp;quot;2010–2011&amp;quot;, [&amp;quot;2010-2011&amp;quot;] = &amp;quot;2010–2011&amp;quot;,&lt;br /&gt;
	                  [&amp;quot;2012&amp;quot;] = &amp;quot;2012–2013&amp;quot;, [&amp;quot;2013&amp;quot;] = &amp;quot;2012–2013&amp;quot;, [&amp;quot;2012–2013&amp;quot;] = &amp;quot;2012–2013&amp;quot;, [&amp;quot;2012-2013&amp;quot;] = &amp;quot;2012–2013&amp;quot;}&lt;br /&gt;
	return editions[year] or &amp;#039;&amp;#039;&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p.dateOutput(frame)&lt;br /&gt;
	--This function fills in the date field of cite map.&lt;br /&gt;
	local edition = p.edition(frame)&lt;br /&gt;
	local dates = {[&amp;quot;2004&amp;quot;] = &amp;quot;2004-01-01&amp;quot;, [&amp;quot;2006&amp;quot;] = &amp;quot;2006-01-01&amp;quot;, [&amp;quot;2008&amp;quot;] = &amp;quot;2008-01-01&amp;quot;, [&amp;quot;2010–2011&amp;quot;] = &amp;quot;2010-01-01&amp;quot;, [&amp;quot;2012–2013&amp;quot;] = &amp;quot;2012-01-01&amp;quot;}&lt;br /&gt;
	return dates[edition]&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
return p&lt;/div&gt;</summary>
		<author><name>imported&gt;Happy5214</name></author>
	</entry>
</feed>