<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://moasspedia.org/w/index.php?action=history&amp;feed=atom&amp;title=Module%3ARequested_move</id>
	<title>Module:Requested move - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://moasspedia.org/w/index.php?action=history&amp;feed=atom&amp;title=Module%3ARequested_move"/>
	<link rel="alternate" type="text/html" href="https://moasspedia.org/w/index.php?title=Module:Requested_move&amp;action=history"/>
	<updated>2026-04-12T14:02:20Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.37.2</generator>
	<entry>
		<id>https://moasspedia.org/w/index.php?title=Module:Requested_move&amp;diff=3112&amp;oldid=prev</id>
		<title>Wikipedia&gt;Wbm1058: Undid revision 941148733 by MSGJ (talk) per followup discussion at Template talk:Requested move#Hide advice when it was followed</title>
		<link rel="alternate" type="text/html" href="https://moasspedia.org/w/index.php?title=Module:Requested_move&amp;diff=3112&amp;oldid=prev"/>
		<updated>2020-04-20T17:57:13Z</updated>

		<summary type="html">&lt;p&gt;Undid revision 941148733 by &lt;a href=&quot;/wiki/Special:Contributions/MSGJ&quot; title=&quot;Special:Contributions/MSGJ&quot;&gt;MSGJ&lt;/a&gt; (&lt;a href=&quot;/w/index.php?title=User_talk:MSGJ&amp;amp;action=edit&amp;amp;redlink=1&quot; class=&quot;new&quot; title=&quot;User talk:MSGJ (page does not exist)&quot;&gt;talk&lt;/a&gt;) per followup discussion at &lt;a href=&quot;/w/index.php?title=Template_talk:Requested_move&amp;amp;action=edit&amp;amp;redlink=1&quot; class=&quot;new&quot; title=&quot;Template talk:Requested move (page does not exist)&quot;&gt;Template talk:Requested move#Hide advice when it was followed&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;-- This module implements {{requested move}}.&lt;br /&gt;
&lt;br /&gt;
-- Load necessary modules&lt;br /&gt;
local getArgs = require(&amp;#039;Module:Arguments&amp;#039;).getArgs&lt;br /&gt;
local tableTools = require(&amp;#039;Module:TableTools&amp;#039;)&lt;br /&gt;
local yesno = require(&amp;#039;Module:Yesno&amp;#039;)&lt;br /&gt;
local mRedirect = require(&amp;#039;Module:Redirect&amp;#039;)&lt;br /&gt;
&lt;br /&gt;
-- Set static values&lt;br /&gt;
local defaultNewPagename = &amp;#039;?&amp;#039; -- Name of new pages that haven&amp;#039;t been specified&lt;br /&gt;
&lt;br /&gt;
local p = {}&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
-- Helper functions&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
 &lt;br /&gt;
local function err(msg, numargs, reason, count)&lt;br /&gt;
	-- Generates a wikitext error message&lt;br /&gt;
	local commented = &amp;#039;&amp;lt;!-- {{subst:requested move|&amp;#039;&lt;br /&gt;
	if count ~= 1 then&lt;br /&gt;
	   commented = commented .. &amp;#039;new1=&amp;#039;&lt;br /&gt;
	end&lt;br /&gt;
	commented = commented .. numargs[1][&amp;#039;new&amp;#039;]&lt;br /&gt;
	for i = 2,count do&lt;br /&gt;
		commented = commented .. string.format(&amp;#039;|current%i=%s&amp;#039;, i, (numargs[i][&amp;#039;current&amp;#039;] or &amp;#039;&amp;#039;))&lt;br /&gt;
		commented = commented .. string.format(&amp;#039;|new%i=%s&amp;#039;, i, (numargs[i][&amp;#039;new&amp;#039;] or &amp;#039;&amp;#039;))&lt;br /&gt;
	end&lt;br /&gt;
	if reason then &lt;br /&gt;
	    commented = commented .. &amp;#039;|reason=&amp;#039; .. reason&lt;br /&gt;
	end&lt;br /&gt;
	commented = commented .. &amp;#039;}} --&amp;gt;&amp;#039;&lt;br /&gt;
	return string.format(&amp;#039;{{error|%s}}&amp;#039;, msg) .. commented&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
local function validateTitle(page, paramName, paramNum) &lt;br /&gt;
	-- Validates a page name, and if it is valid, returns true and the title&lt;br /&gt;
	-- object for that page. If it is not valid, returns false and the&lt;br /&gt;
	-- appropriate error message.&lt;br /&gt;
&lt;br /&gt;
	-- Check for a small subset of characters that cannot be used in MediaWiki&lt;br /&gt;
	-- titles. For the full set of restrictions, see&lt;br /&gt;
	-- [[Wikipedia:Page name#Technical restrictions and limitations]]. This is&lt;br /&gt;
	-- also covered by the invalid title check, but with this check we can give&lt;br /&gt;
	-- a more specific error message.&lt;br /&gt;
	local invalidChar = page:match(&amp;#039;[#&amp;lt;&amp;gt;%[%]|{}]&amp;#039;)&lt;br /&gt;
	if invalidChar then&lt;br /&gt;
		local msg = &amp;#039;Invalid character &amp;quot;&amp;#039;&lt;br /&gt;
			.. invalidChar&lt;br /&gt;
			.. &amp;#039;&amp;quot; found in the &amp;quot;&amp;#039;&lt;br /&gt;
			.. paramName&lt;br /&gt;
			.. paramNum&lt;br /&gt;
			.. &amp;#039;&amp;quot; parameter&amp;#039;&lt;br /&gt;
		return false, msg&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Get the title object. This also checks for invalid titles that aren&amp;#039;t&lt;br /&gt;
	-- covered by the previous check.&lt;br /&gt;
	local titleObj = mw.title.new(page)&lt;br /&gt;
	if not titleObj then&lt;br /&gt;
		local msg = &amp;#039;Invalid title detected in parameter &amp;quot;&amp;#039;&lt;br /&gt;
			.. paramName&lt;br /&gt;
			.. paramNum &lt;br /&gt;
			.. &amp;#039;&amp;quot;; check for [[Wikipedia:Page name#&amp;#039;&lt;br /&gt;
			.. &amp;#039;Technical restrictions and limitations|invalid characters]]&amp;#039;&lt;br /&gt;
		return false, msg&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Check for interwiki links. Titles with interwikis make valid title&lt;br /&gt;
	-- objects, but cannot be created on the local wiki.&lt;br /&gt;
	local interwiki = titleObj.interwiki&lt;br /&gt;
	if interwiki and interwiki ~= &amp;#039;&amp;#039; then&lt;br /&gt;
		local msg = &amp;#039;Invalid title detected in parameter &amp;quot;&amp;#039;&lt;br /&gt;
			.. paramName&lt;br /&gt;
			.. paramNum &lt;br /&gt;
			.. &amp;#039;&amp;quot;; has [[Help:Interwiki linking|interwiki prefix]] &amp;quot;&amp;#039;&lt;br /&gt;
			.. titleObj.interwiki&lt;br /&gt;
			.. &amp;#039;:&amp;quot;&amp;#039;&lt;br /&gt;
		return false, msg&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	return true, titleObj&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
-- Validate title entry point (used at [[Template:RMassist/core]])&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
function p.validateTitle(frame)&lt;br /&gt;
	local value = frame.args[1]&lt;br /&gt;
	local validTitle, currentTitle = validateTitle(value or &amp;#039;&amp;#039;, &amp;#039;1&amp;#039;, &amp;#039;&amp;#039;)&lt;br /&gt;
	if not validTitle then&lt;br /&gt;
		-- If invalid, the second parameter is the error message.&lt;br /&gt;
		local msg = currentTitle&lt;br /&gt;
		return msg&lt;br /&gt;
	end&lt;br /&gt;
	return &amp;#039;yes&amp;#039;&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
-- Main function&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
function p.main(frame)&lt;br /&gt;
	----------------------------------------------------------------------------&lt;br /&gt;
	-- Initialise variables and preprocess the arguments&lt;br /&gt;
	----------------------------------------------------------------------------&lt;br /&gt;
	&lt;br /&gt;
	local args = getArgs(frame, {parentOnly = true})&lt;br /&gt;
	local title = mw.title.getCurrentTitle()&lt;br /&gt;
&lt;br /&gt;
	--[[&lt;br /&gt;
	-- To iterate over the current1, new1, current2, new2, ... arguments&lt;br /&gt;
	-- we get an array of tables sorted by number and compressed so that&lt;br /&gt;
	-- it can be traversed with ipairs.	The table format looks like this:&lt;br /&gt;
	-- {&lt;br /&gt;
	--  {current = x, new = y, num = 1},&lt;br /&gt;
	--  {current = z, new = q, num = 2},&lt;br /&gt;
	--  ...&lt;br /&gt;
	-- }&lt;br /&gt;
	-- The &amp;quot;num&amp;quot; field is used to correctly preserve the number of the parameter&lt;br /&gt;
	-- that was used, in case users skip any numbers in the invocation.&lt;br /&gt;
	--&lt;br /&gt;
	-- The current1 parameter is a special case, as it does not need to be&lt;br /&gt;
	-- specified. To avoid clashes with later current parameters, we need to&lt;br /&gt;
	-- add it to the args table manually.&lt;br /&gt;
	--&lt;br /&gt;
	-- Also, we allow the first positional parameter to be an alias for the&lt;br /&gt;
	-- new1 parameter, so that the syntax for the old templates&lt;br /&gt;
	-- {{requested move}} and {{move-multi}} will both be supported.&lt;br /&gt;
	--&lt;br /&gt;
	-- The &amp;quot;multi&amp;quot; variable tracks whether we are using the syntax previously&lt;br /&gt;
	-- produced by {{requested move}}, or the syntax previously produced by&lt;br /&gt;
	-- {{move-multi}}. For the former, multi is false, and for the latter it is&lt;br /&gt;
	-- true.&lt;br /&gt;
	--]]&lt;br /&gt;
	if not args.current1 then&lt;br /&gt;
		args.current1 = title.subjectPageTitle.prefixedText&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Find the first new page title, if specified, and keep a record of the&lt;br /&gt;
	-- prefix used to make it; the prefix will be used later to make error&lt;br /&gt;
	-- messages.&lt;br /&gt;
	local firstNewParam&lt;br /&gt;
	if args.new1 then&lt;br /&gt;
		firstNewParamPrefix = &amp;#039;new&amp;#039;&lt;br /&gt;
	elseif args[1] then&lt;br /&gt;
		args.new1 = args[1]&lt;br /&gt;
		firstNewParamPrefix = &amp;#039;&amp;#039;&lt;br /&gt;
	else&lt;br /&gt;
		firstNewParamPrefix = &amp;#039;&amp;#039;&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Build the sorted argument table.&lt;br /&gt;
	local argsByNum = {}&lt;br /&gt;
	for k, v in pairs(args) do&lt;br /&gt;
		k = tostring(k)&lt;br /&gt;
		local prefix, num = k:match(&amp;#039;^(%l*)([1-9][0-9]*)$&amp;#039;)&lt;br /&gt;
		if prefix == &amp;#039;current&amp;#039; or prefix == &amp;#039;new&amp;#039; then&lt;br /&gt;
			num = tonumber(num)&lt;br /&gt;
			local subtable = argsByNum[num] or {}&lt;br /&gt;
			subtable[prefix] = v&lt;br /&gt;
			subtable.num = num&lt;br /&gt;
			argsByNum[num] = subtable&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	argsByNum = tableTools.compressSparseArray(argsByNum)&lt;br /&gt;
&lt;br /&gt;
	-- Calculate the number of arguments and whether we are dealing with a&lt;br /&gt;
	-- multiple nomination.&lt;br /&gt;
	local argsByNumCount = #argsByNum&lt;br /&gt;
	local multi&lt;br /&gt;
	if argsByNumCount &amp;gt;= 2 then&lt;br /&gt;
		multi = true&lt;br /&gt;
	else&lt;br /&gt;
		multi = false&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	--[[&lt;br /&gt;
	-- Validate new params.&lt;br /&gt;
	-- This check ensures we don&amp;#039;t have any absent new parameters, and that&lt;br /&gt;
	-- users haven&amp;#039;t simply copied in the values from the documentation page.&lt;br /&gt;
	--]]&lt;br /&gt;
	if multi then&lt;br /&gt;
		for i, t in ipairs(argsByNum) do&lt;br /&gt;
			local new = t.new&lt;br /&gt;
			local num = t.num&lt;br /&gt;
			if not new or new == &amp;#039;New title for page &amp;#039; .. tostring(num) then&lt;br /&gt;
				argsByNum[i].new = defaultNewPagename&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	else&lt;br /&gt;
		local new = argsByNum[1].new&lt;br /&gt;
		if not new or new == &amp;#039;NewName&amp;#039; then&lt;br /&gt;
			argsByNum[1].new = defaultNewPagename&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	----------------------------------------------------------------------------&lt;br /&gt;
	-- Error checks&lt;br /&gt;
	----------------------------------------------------------------------------&lt;br /&gt;
	&lt;br /&gt;
	-- Subst check&lt;br /&gt;
	if not mw.isSubsting() then&lt;br /&gt;
		local lb = mw.text.nowiki(&amp;#039;{{&amp;#039;)&lt;br /&gt;
		local rb = mw.text.nowiki(&amp;#039;}}&amp;#039;)&lt;br /&gt;
		local msg = &amp;#039;&amp;lt;strong class=&amp;quot;error&amp;quot;&amp;gt;&amp;#039;&lt;br /&gt;
			.. &amp;#039;This template must be [[Wikipedia:Template substitution|substituted]];&amp;#039;&lt;br /&gt;
			.. &amp;#039; replace %srequested move%s with %ssubst:requested move%s&amp;#039;&lt;br /&gt;
			.. &amp;#039;&amp;lt;/strong&amp;gt;&amp;#039;&lt;br /&gt;
		msg = string.format(msg, lb, rb, lb, rb)&lt;br /&gt;
		return msg&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	-- Check we are on a talk page&lt;br /&gt;
	if not title.isTalkPage then&lt;br /&gt;
		local msg = &amp;#039;[[Template:Requested move]] must be used in a TALKSPACE, e.g., [[%s:%s]]&amp;#039;&lt;br /&gt;
		msg = string.format(msg, mw.site.namespaces[title.namespace].talk.name, title.text)&lt;br /&gt;
		return err(msg, argsByNum, args.reason, argsByNumCount)&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	-- Check the arguments&lt;br /&gt;
	local currentDupes, newDupes = {}, {}&lt;br /&gt;
	for i, t in ipairs(argsByNum) do&lt;br /&gt;
		local current = t.current&lt;br /&gt;
		local new = t.new&lt;br /&gt;
		local num = t.num&lt;br /&gt;
		local validCurrent&lt;br /&gt;
		local currentTitle&lt;br /&gt;
		local subjectSpace&lt;br /&gt;
&lt;br /&gt;
		-- Check for invalid or missing currentn parameters&lt;br /&gt;
		-- This check must come first, as mw.title.new will give an error if&lt;br /&gt;
		-- it is given invalid input.&lt;br /&gt;
		if not current then&lt;br /&gt;
			local msg = &amp;#039;&amp;quot;current%d&amp;quot; parameter missing;&amp;#039;&lt;br /&gt;
				.. &amp;#039; please add it or remove the &amp;quot;new%d&amp;quot; parameter&amp;#039;&lt;br /&gt;
			msg = string.format(msg, num, num)&lt;br /&gt;
			return err(msg, argsByNum, args.reason, argsByNumCount)&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
		-- Get the currentn title object, and check for invalid titles. This check&lt;br /&gt;
		-- must come before the namespace and existence checks, as they will&lt;br /&gt;
		-- produce script errors if the title object doesn&amp;#039;t exist.&lt;br /&gt;
		validCurrent, currentTitle = validateTitle(current, &amp;#039;current&amp;#039;, num)&lt;br /&gt;
		if not validCurrent then&lt;br /&gt;
			-- If invalid, the second parameter is the error message.&lt;br /&gt;
			local msg = currentTitle &lt;br /&gt;
			return err(msg, argsByNum, args.reason, argsByNumCount)&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
		-- Category namespace check&lt;br /&gt;
		subjectSpace = mw.site.namespaces[currentTitle.namespace].subject.id&lt;br /&gt;
		if subjectSpace == 14 then&lt;br /&gt;
			local msg = &amp;#039;[[Template:Requested move]] is not for categories,&amp;#039;&lt;br /&gt;
				.. &amp;#039; see [[Wikipedia:Categories for discussion]]&amp;#039;&lt;br /&gt;
			return err(msg, argsByNum, args.reason, argsByNumCount)&lt;br /&gt;
		&lt;br /&gt;
		-- File namespace check&lt;br /&gt;
		elseif subjectSpace == 6 then&lt;br /&gt;
			local msg = &amp;#039;[[Template:Requested move]] is not for files;&amp;#039;&lt;br /&gt;
				.. &amp;#039; see [[Wikipedia:Moving a page#Moving a file page]]&amp;#039;&lt;br /&gt;
				.. &amp;#039; (use [[Template:Rename media]] instead)&amp;#039;&lt;br /&gt;
			return err(msg, argsByNum, args.reason, argsByNumCount)&lt;br /&gt;
&lt;br /&gt;
		-- Draft and User namespace check&lt;br /&gt;
		elseif subjectSpace == 2 or subjectSpace == 118 then&lt;br /&gt;
			local msg = &amp;#039;[[Template:Requested move]] is not for moves from draft or user space.&amp;#039;&lt;br /&gt;
				.. &amp;#039;&amp;lt;br&amp;gt;If you would like to submit your draft for review, add &amp;lt;code&amp;gt;{{tlf|subst:submit}}&amp;lt;/code&amp;gt;&amp;#039;&lt;br /&gt;
				    .. &amp;#039;to the top of the page.&amp;#039;&lt;br /&gt;
				.. &amp;#039;&amp;lt;br&amp;gt;Otherwise, see [[Help:How to move a page]] for instructions.&amp;#039;&lt;br /&gt;
				.. &amp;#039;&amp;lt;br&amp;gt;If you cannot move it yourself, see [[Wikipedia:Requested moves#Requesting technical moves|Requesting technical moves]].&amp;#039;&lt;br /&gt;
			return err(msg, argsByNum, args.reason, argsByNumCount)&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
		-- Request to move a single page must be placed on that page&amp;#039;s talk, or the page it redirects to&lt;br /&gt;
		if not multi and args.current1 ~= title.subjectPageTitle.prefixedText then&lt;br /&gt;
			local idealpage = mw.title.new(args.current1).talkPageTitle&lt;br /&gt;
			local rtarget = mRedirect.getTarget(idealpage)&lt;br /&gt;
			if rtarget == title.prefixedText then&lt;br /&gt;
				multi = true&lt;br /&gt;
			else&lt;br /&gt;
				local msg = &amp;#039;Request to move a single page must be placed on that page\&amp;#039;s talk or the page its talk redirects to&amp;#039;&lt;br /&gt;
				return err(msg, argsByNum, args.reason, argsByNumCount)&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
		-- Check for non-existent titles.&lt;br /&gt;
		if not currentTitle.exists then&lt;br /&gt;
			local msg = &amp;#039;Must create [[:%s]] before requesting that it be moved&amp;#039;&lt;br /&gt;
			msg = string.format(msg, current)&lt;br /&gt;
			return err(msg, argsByNum, args.reason, argsByNumCount)&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
		-- Check for duplicate current titles&lt;br /&gt;
		-- We know the id isn&amp;#039;t zero because we have already checked for&lt;br /&gt;
		-- existence.&lt;br /&gt;
		local currentId = currentTitle.id&lt;br /&gt;
		if currentDupes[currentId] then&lt;br /&gt;
			local msg = &amp;#039;Duplicate title detected (&amp;quot;&amp;#039;&lt;br /&gt;
				.. currentTitle.prefixedText&lt;br /&gt;
				.. &amp;#039;&amp;quot;); cannot move the same page to two different places&amp;#039;&lt;br /&gt;
			return err(msg, argsByNum, args.reason, argsByNumCount)&lt;br /&gt;
		else&lt;br /&gt;
			currentDupes[currentId] = true&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
		-- Check for invalid new titles. This check must come before the&lt;br /&gt;
		-- duplicate title check for new titles, as it will produce a script&lt;br /&gt;
		-- error if the title object doesn&amp;#039;t exist.&lt;br /&gt;
		local validNew, newTitle = validateTitle(&lt;br /&gt;
			new,&lt;br /&gt;
			multi and &amp;#039;new&amp;#039; or firstNewParamPrefix,&lt;br /&gt;
			num&lt;br /&gt;
		)&lt;br /&gt;
		if not validNew then&lt;br /&gt;
			-- If invalid, the second parameter is the error message.&lt;br /&gt;
			local msg = newTitle&lt;br /&gt;
			return err(msg, argsByNum, args.reason, argsByNumCount)&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
		-- Check for duplicate new titles.&lt;br /&gt;
		-- We can&amp;#039;t use the page_id, as new pages might not exist, and therefore&lt;br /&gt;
		-- multiple pages may have an id of 0. Use the prefixedText as a&lt;br /&gt;
		-- reasonable fallback. We also need to check that we aren&amp;#039;t using the&lt;br /&gt;
		-- default new page name, as we don&amp;#039;t want it to be treated as a duplicate&lt;br /&gt;
		-- page if more than one new page name has been omitted.&lt;br /&gt;
		local newPrefixedText = newTitle.prefixedText&lt;br /&gt;
		if newPrefixedText ~= defaultNewPagename then&lt;br /&gt;
			if newDupes[newPrefixedText] then&lt;br /&gt;
				local msg = &amp;#039;Duplicate title detected (&amp;quot;&amp;#039;&lt;br /&gt;
					.. newTitle.prefixedText&lt;br /&gt;
					.. &amp;#039;&amp;quot;); cannot move two different pages to the same place&amp;#039;&lt;br /&gt;
				return err(msg, argsByNum, args.reason, argsByNumCount)&lt;br /&gt;
			else&lt;br /&gt;
				newDupes[newPrefixedText] = true&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	----------------------------------------------------------------------------&lt;br /&gt;
	-- Generate the heading&lt;br /&gt;
	----------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
	-- For custom values of |heading=, use those.&lt;br /&gt;
	-- For |heading=no, |heading=n, etc., don&amp;#039;t include a heading.&lt;br /&gt;
	-- Otherwise use the current date as a heading.&lt;br /&gt;
	local heading = args.heading or args.header&lt;br /&gt;
	local useHeading = yesno(heading, heading)&lt;br /&gt;
	if heading and useHeading == heading then&lt;br /&gt;
		heading = &amp;#039;== &amp;#039; .. heading .. &amp;#039; ==\n\n&amp;#039;&lt;br /&gt;
	elseif useHeading == false then&lt;br /&gt;
		heading = &amp;#039;&amp;#039;&lt;br /&gt;
	else&lt;br /&gt;
		local lang = mw.language.getContentLanguage()&lt;br /&gt;
		local headingDate = lang:formatDate(&amp;#039;j F Y&amp;#039;)&lt;br /&gt;
		heading = &amp;#039;== Requested move &amp;#039; .. headingDate .. &amp;#039; ==\n\n&amp;#039;&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	----------------------------------------------------------------------------&lt;br /&gt;
	-- Build the {{requested move/dated}} invocation&lt;br /&gt;
	----------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
	local rmd = {}&lt;br /&gt;
	rmd[#rmd + 1] = &amp;#039;{{requested move/dated&amp;#039;&lt;br /&gt;
&lt;br /&gt;
	if multi then&lt;br /&gt;
		rmd[#rmd + 1] = &amp;#039;|multiple=yes&amp;#039;&lt;br /&gt;
		rmd[#rmd + 1] = &amp;#039;\n|current1=&amp;#039; .. argsByNum[1].current&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	--[[&lt;br /&gt;
	-- The first new title. This is used both by single and by multi; for single&lt;br /&gt;
	-- it is the only parameter used. For single the parameter name is the first&lt;br /&gt;
	-- positional parameter, and for multi the parameter name is &amp;quot;new1&amp;quot;.&lt;br /&gt;
	--]]&lt;br /&gt;
	local new1param = multi and &amp;#039;new1=&amp;#039; or &amp;#039;&amp;#039;&lt;br /&gt;
	rmd[#rmd + 1] = &amp;#039;|&amp;#039; .. new1param .. argsByNum[1].new&lt;br /&gt;
&lt;br /&gt;
	-- Add the rest of the arguments for multi.&lt;br /&gt;
	if multi then&lt;br /&gt;
		for i = 2, argsByNumCount do&lt;br /&gt;
			local t = argsByNum[i]&lt;br /&gt;
			local numString = tostring(i)&lt;br /&gt;
			local current = t.current&lt;br /&gt;
			local new = t.new&lt;br /&gt;
			rmd[#rmd + 1] = &amp;#039;|current&amp;#039; .. numString .. &amp;#039;=&amp;#039; .. current&lt;br /&gt;
			rmd[#rmd + 1] = &amp;#039;|new&amp;#039; .. numString .. &amp;#039;=&amp;#039; .. new&lt;br /&gt;
		end&lt;br /&gt;
		-- The old multi template always has a bar before the closing curly&lt;br /&gt;
		-- braces, so we will do that too.&lt;br /&gt;
		rmd[#rmd + 1] = &amp;#039;|&amp;#039;&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	rmd[#rmd + 1] = &amp;#039;}}&amp;#039;&lt;br /&gt;
	rmd = table.concat(rmd)&lt;br /&gt;
&lt;br /&gt;
	----------------------------------------------------------------------------&lt;br /&gt;
	-- Generate the list of links to the pages to be moved&lt;br /&gt;
	----------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
	local linkList = {}&lt;br /&gt;
	for i, t in ipairs(argsByNum) do&lt;br /&gt;
		local current = t.current&lt;br /&gt;
		local new = t.new&lt;br /&gt;
		local msg = &amp;#039;\n%s[[:%s]] → &amp;#039;&lt;br /&gt;
		if new ~= defaultNewPagename then&lt;br /&gt;
			msg = msg .. &amp;#039;{{no redirect|%s}}&amp;#039;&lt;br /&gt;
		else&lt;br /&gt;
			msg = msg .. &amp;#039;%s&amp;#039;&lt;br /&gt;
		end&lt;br /&gt;
		local item = string.format(&lt;br /&gt;
			msg,&lt;br /&gt;
			multi and &amp;#039;* &amp;#039; or &amp;#039;&amp;#039;, -- Don&amp;#039;t make a list for single page moves.&lt;br /&gt;
			current,&lt;br /&gt;
			new&lt;br /&gt;
		)&lt;br /&gt;
		linkList[#linkList + 1] = item&lt;br /&gt;
	end&lt;br /&gt;
	linkList = table.concat(linkList)&lt;br /&gt;
&lt;br /&gt;
	----------------------------------------------------------------------------&lt;br /&gt;
	-- Reason and talk blurb&lt;br /&gt;
	----------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
	-- Reason&lt;br /&gt;
	local reason = args.reason or args[2] or &amp;#039;Please place your rationale for the proposed move here.&amp;#039;&lt;br /&gt;
	reason = &amp;#039;– &amp;#039; .. reason&lt;br /&gt;
	if yesno(args.sign or args.sig or args.signature or &amp;#039;unspecified&amp;#039;, not reason:match(&amp;quot;~~~$&amp;quot;)) then&lt;br /&gt;
		reason = reason .. &amp;#039; ~~~~&amp;#039;&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Talk blurb&lt;br /&gt;
	local talk&lt;br /&gt;
	if yesno(args.talk, true) then&lt;br /&gt;
		talk = frame:expandTemplate{title = &amp;#039;Requested move/talk&amp;#039;}&lt;br /&gt;
	else&lt;br /&gt;
		talk = &amp;#039;&amp;#039;&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	----------------------------------------------------------------------------&lt;br /&gt;
	-- Assemble the output&lt;br /&gt;
	----------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
	-- The old templates start with a line break, so we will do that too.&lt;br /&gt;
	local ret = string.format(&lt;br /&gt;
		&amp;#039;\n%s%s\n%s%s%s%s&amp;#039;,&lt;br /&gt;
		heading,&lt;br /&gt;
		rmd,&lt;br /&gt;
		linkList,&lt;br /&gt;
		multi and &amp;#039;\n&amp;#039; or &amp;#039; &amp;#039;,&lt;br /&gt;
		reason,&lt;br /&gt;
		talk&lt;br /&gt;
	)&lt;br /&gt;
	return ret&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
return p&lt;/div&gt;</summary>
		<author><name>Wikipedia&gt;Wbm1058</name></author>
	</entry>
</feed>