Module:Cite Q: Difference between revisions

Content deleted Content added
create;
 
cleanup
Line 18:
arguments:
args - pointer to the parameter arguments table from the template call
 
from args, this function will get:
qid - value from |qid= parameter; the Q-id of the source (book, etc.) in qid
wdl - value from the |wdlinks= parameter; a boolean passed to enable links to Wikidata when no article exists
Line 29 ⟶ 27:
local function get_authors (args, qid, wdl)
local propertyID = "P50"
-- local qid = frame.args.qid
-- if qid and (#qid == 0) then qid = nil end
-- wdlinks is a boolean passed to enable links to Wikidata when no article exists
-- if "false" or "no" or "0" is passed set it false
-- if nothing or an empty string is passed set it false
-- local wdl = frame.args.wdlinks
if wdl and (#wdl > 0) then
wdl = wdl:lower()
Line 115 ⟶ 109:
local parameter_name = 'author' .. k;
args[parameter_name] = v;
-- out[k] = "|author" .. k .. "=" .. v
end
-- return table.concat(out, " ")
end
end