Jump to content

Module:Template link general: Difference between revisions

m
(update code - remove trailing blank parameters)
 
(2 intermediate revisions by one other user not shown)
Line 102: Line 102:
while args[i] do
while args[i] do
local val = args[i]
local val = args[i]
if val ~= nil then val = mw.text.unstripNoWiki(val) else break end
textPartBuffer = textPartBuffer .. '|'
textPartBuffer = textPartBuffer .. '|'
if val ~= "" then
if val ~= "" then
if _ne(args.nowiki) then val = nw(val) end
if _ne(args.nowiki) then
-- Unstrip nowiki tags first because calling nw on something that already contains nowiki tags will
-- mangle the nowiki strip marker and result in literal UNIQ...QINU showing up
val = nw(mw.text.unstripNoWiki(val))
end
if italic then val = '<span style="font-style:italic;">' .. val .. '</span>' end
if italic then val = '<span style="font-style:italic;">' .. val .. '</span>' end
textPart = textPart .. textPartBuffer .. val
textPart = textPart .. textPartBuffer .. val
Cookies help us deliver our services. By using our services, you agree to our use of cookies.