Module:IsValidPageName

Gikan sa Bikol Sentral na Wikipedia, an talingkas na ensiklopedya
Jump to navigation Jump to search
Documentation icon Dokumentasyon nin Modyul[gibuhon]
-- This module implements [[Plantilya:isValidPageName]].

local export = {}

function export.isValidPageName(frame)
	local success, res = pcall(mw.title.new, frame.args[1])
	if success and res then
		return "valid"
	else
		return ""
	end
end

return export