Module:Ifexists

local p = {} function p.exists(frame) local sText = frame.args[1] local sTrueAction = frame.args[2] local sFalseAction = frame.args[3] if (sText) then if mw.title.new(sText).exists then return sTrueAction else return sFalseAction end end end

return p -- Use: