יחידה:PropertyLink: הבדלים בין גרסאות בדף

DK
DK
שורה 562: שורה 562:
local raw = mw.wikibase.getEntity( string.upper( frame.args[1] ) )["sitelinks"]
local raw = mw.wikibase.getEntity( string.upper( frame.args[1] ) )["sitelinks"]
local interwikis = ''
local interwikis = ''
for site, title in pairs(raw) do
for site, val in pairs(raw) do
truncated, found = string.gsub(site, 'wiki$', '')
truncated, found = string.gsub(site, 'wiki$', '')
if found then interwikis = interwikis .. '[[' .. truncated .. ':' .. title .. ']]' end
if found then interwikis = interwikis .. '[[' .. truncated .. ':' .. val.title .. ']]' end
end
end
return interwikis
return interwikis