Documentation for this module may be created at Module:Sandbox/DannyS712/learning/doc
local p = {}; --All lua modules on Wikipedia must begin by defining a variable
--that will hold their externally accessible functions.
--Such variables can have whatever name you want and may
--also contain various data as well as functions.
function p.hello( frame ) --"frame" will contain the data that Wikipedia sends this function when it runs.
local str = "Hello World!"
return str
end
function p.name ( frame )
parent = frame:getParent()
local title = parent:getTitle()
link = frame.args["link"]
if link == "yes" or link == "y" then
title = "[[" .. title .. "]]"
end
explain = frame.args["explain"]
if explain == "yes" or explain == "y" then
title = "This module was called from: " .. title
end
return title
end
return p
