Changes
Jump to navigation
Jump to search
Line 61:
Line 61:
− +
Line 71:
Line 71:
− +
no edit summary
local langList = mw.language.getFallbacksFor(lang)
local langList = mw.language.getFallbacksFor(lang)
table.insert(langList, 1, lang)
table.insert(langList, 1, lang)
local langlist = {"en", "en"}
local langlist = {"en"}
-- get label (visible part of the link)
-- get label (visible part of the link)
for _, language in ipairs(langList) do -- loop over language fallback list looking for label in the specific language
for _, language in ipairs(langList) do -- loop over language fallback list looking for label in the specific language
if label then break end -- label found and we are done
if label then break end -- label found and we are done
end
end
label = "some text" .. langList[2]
label = "some text" .. langList[0]
if not label then -- no labels found, so just show the q-code
if not label then -- no labels found, so just show the q-code
label = item
label = item