Module:InfoboxImage: Difference between revisions

m
1 revision imported from wikipedia:Module:InfoboxImage
(don't use alt as a title when title not set)
m (1 revision imported from wikipedia:Module:InfoboxImage)
 
(4 intermediate revisions by 4 users not shown)
Line 12:
-- suppressplaceholder - if yes then checks to see if image is a placeholder and suppresses it
-- link - page to visit when clicking on image
-- class - HTML classes to add to the image
-- Outputs:
-- Formatted image.
Line 172 ⟶ 173:
elseif mw.ustring.sub(image,1,1) == "<" then
return image;
elseif mw.ustring.sub(image,1,58) == mw.ustring.char(127).."'\"`UNIQ" then
-- Found strip marker at begining, so pass don't process at all
return image;
elseif mw.ustring.sub(image,4,9) == "`UNIQ-" then
-- Found strip marker at begining, so pass don't process at all
return image;
Line 190 ⟶ 188:
local upright = frame.args["upright"] or "";
local thumbtime = frame.args["thumbtime"] or "";
local center = frame.args["center"];
local class = frame.args["class"];
-- remove prefix if exists
Line 256 ⟶ 255:
if thumbtime ~= "" then
result = result .. "|thumbtime=" .. thumbtime;
end
if class ~= nil and class ~= "" then
result = result .. "|class=" .. class;
end
-- if alt value is a keyword then do not use as a description
rtl-contributors
1,630

edits