More actions
Created page with "local p = {} local function isHiddenOrUseless(id, ns) -- escludi roba tecnica/di sistema if id < 0 then return true end if ns.name == '' then return true end -- spesso non serve elencare Talk if ns.isTalk then return true end -- escludi namespace tipici di sistema (puoi togliere ciò che vuoi) local blacklist = { ["Special"] = true, ["MediaWiki"] = true, } if blacklist[ns.name] then return true end return false end function p.list(frame) local out = {}..." |
No edit summary |
||
| (One intermediate revision by the same user not shown) | |||
| Line 1: | Line 1: | ||
local p = {} | local p = {} | ||
function p.list(frame) | function p.list(frame) | ||
local out = {} | local out = {} | ||
for id, ns in pairs(mw.site.namespaces) do | for id, ns in pairs(mw.site.namespaces) do | ||
if | if id >= 0 and ns.name and ns.name ~= '' and not ns.isTalk then | ||
table.insert(out, "* " .. ns.name) | |||
table.insert(out, | |||
end | end | ||
end | end | ||
table.sort(out) | table.sort(out) | ||
return table.concat(out, "\n") | return table.concat(out, "\n") | ||
Latest revision as of 09:26, 6 February 2026
Documentation for this module may be created at Module:Namespaces/doc