Module:Sandbox

--Hey, this is a sandbox for Lua! --Be careful :O

local f = {}

function f.main(frame) local description if frame.args["description"]=="" or frame.args["description"]==nil then description="No description provided " else description=frame.args["description"] end local type = mw.ustring.lower(frame.args["type"] or "") local source if frame.args["source"]=="" or frame.args["description"]==nil then source="No source specified " else source=frame.args["source"] end local result = {} local t = {} t = { ['art'] = "Official artwork ", --removing other types for testing purposes }	type = t[type] or "No type specified. " local license = mw.title.getCurrentTitle:getContent if license:find('%{%{License%-') then license = "" else license = "" end local panel = ' File information  '.. license ..'' if mw.title.getCurrentTitle.namespace ~= 6 then panel = "Hey! The module does not spawn here because it's intended to be used on File pages only." end table.insert(result, panel) return table.concat(result, "") end

return f