Module:Link:修订间差异

无编辑摘要
无编辑摘要
第8行: 第8行:
end
end
return result
return result
end
function link(page,name)
return '[['..page..'列表#'..name..'|'..name..']]'
end
end


function p.link(frame)
function p.link(frame)
 
local page,text=mw.getCurrentFrame():getParent().args[1],mw.getCurrentFrame():getParent().args[2]
local a,b,c = text
:match('(.*?) (vs) (.*?)')
:match('(.*?) (vs.) (.*?)')
if a and b and c then
return link(a)..b..link(c)
end
end
end


return p
return p