Module:Sandbox/54nd60x/test: Difference between revisions

Content deleted Content added
No edit summary
No edit summary
 
(17 intermediate revisions by the same user not shown)
Line 17:
end -- end of the function "hello"
function p.hello_tokeyboard(frame) -- Add another function
local name = frame.args[1] -- To access arguments passed to a module, use `frame.args`
-- `frame.args[1]` refers to the first unnamed parameter
-- given to the module
return "{{https://en.wikipedia.org/w/index.php?title=" .. name .. "}}&action=edit&editintro=Module:Sandbox/54nd60x/test/doc" -- `..` concatenates strings. This will return a customized
-- greeting depending on the name given, such as "Hello, Fred!"
end