A Wikiszótárból, a nyitott szótárból
A modult a Modul:makeWikidataLinkEN/doc lapon tudod dokumentálni
local p = {}
function p.getWikidataId()
local title = mw.title.getCurrentTitle().text
local entityId = mw.wikibase.getEntityIdForTitle( title, 'enwiki' )
if entityId then
local string = "[[d:" .. entityId .. "|Wikidata]]"
return string
else
return nil
end
end
return p