Module:InfoboxImage: Difference between revisions

add page param from sandbox changes by User:Xover
(Allow upright=yes to add "|upright" without a value (File:Name.png|frameless|upright). Tested with /sandbox and /testcases. Announced on talk page 7 days ago, no comments posted.)
(add page param from sandbox changes by User:Xover)
Line 1:
-- Inputs:
-- image - Can either be a bare filename (with or without the File:/Image: prefix) or a fully formatted image link
-- page - page to display for multipage images (DjVu)
-- size - size to display the image
-- maxsize - maximum size for image
Line 175 ⟶ 176:
else
local result = "";
local page = frame.args["page"];
local size = frame.args["size"];
local maxsize = frame.args["maxsize"];
Line 217 ⟶ 219:
result = "[[File:" .. image;
if page ~= "" and page ~= nil then
result = result .. "|page=" .. page;
end
if size ~= "" and size ~= nil then
result = result .. "|" .. size;
Anonymous user