Module:EmailTracking

From Wikivoyage
This is an old revision of this page, as edited by Andyrom75 (talk | contribs) at 23:22, 17 December 2021.
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

--[[
	Source script:	https://it.wikivoyage.org/wiki/Module:EmailTracking
	Maintainer:		Andyrom75
]]
local p = {}
 
function p.EmailTracking(frame)
	return frame.args and p.EmailTrackingValue( frame.args.email ) or ''
end

function p.EmailTrackingValue( email, demo )
    if mw.ustring.match(email or '','@.*@') then
	        return '[[' .. (mw.title.getCurrentTitle().namespace == 0 and '' or ':' ) .. 'Category:Listing with multiple email addresses]]<span class="phoneinfo" style="display:none;">MULTIPLE-EMAIL</span>'
    end
    return ''
end
 
return p