Module:NextText
Sauter à la navigation
Sauter à la recherche
La documentation pour ce module peut être créée à Module:NextText/doc
local p = {} --local p = {} -- p est l’abrégé de paquet
function p.Next( frame )
local title = frame.args[1]
if string.match(title, ".+%([0-9]+%)") ~= nil then
local _, _, a, b = string.find(title, "(.+%()([0-9]+)")
b = tostring(tonumber(b)+1)
return a..b..")"
end
end
function p.Previous( frame )
local title = frame.args[1]
if string.match(title, ".+%([0-9]+%)") ~= nil then
local _, _, a, b = string.find(title, "(.+%()([0-9]+)")
if tonumber(b) >= 1 then
b = tostring(tonumber(b)-1)
return a..b..")"
end
end
end
return p