Module:TestLang/abaraz
Umn
| Wad iga module sandbox page id Module:TestLang. |
local p = {}
function p.test()
local tags = {
"str", "en-nz", "akk", "rhg-arab", "ojp-hira",
"abq-latn", "hsn-hant", "de-formal", "bez", "sjk","ar"
}
local names = mw.language.fetchLanguageNames('shi-latn', 'all') -- change 'en' to local language code if needed
local result = {}
for _, tag in ipairs(tags) do
local name = names[tag] or '❌ not found'
table.insert(result, string.format('<code>%s</code> = %s', tag, name))
end
return table.concat(result, '<br>')
end
return p