Editing Module:No ping
Jump to navigation
Jump to search
The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then publish the changes below to finish undoing the edit.
Latest revision | Your text | ||
Line 15: | Line 15: | ||
local url = fullUrl(mw.site.namespaces.User.name .. ':' .. username) | local url = fullUrl(mw.site.namespaces.User.name .. ':' .. username) | ||
url = tostring(url) | url = tostring(url) | ||
local label = args['label' .. tostring(i)] | local label = args['label' .. tostring(i)] or username | ||
url = format('[%s %s]', url, label | local color = '#cc2200' | ||
if mw.title.new(username, mw.site.namespaces.User.name).exists then color = '#0645ad' end | |||
label = '<span style="color:' .. color .. '">' .. label .. '</span>' | |||
url = format('[%s %s]', url, label) | |||
ret[#ret + 1] = url | ret[#ret + 1] = url | ||
end | end |