« Module:Version imprimable » : différence entre les versions
Contenu supprimé Contenu ajouté
Saut de page entre chapitres, permet l'optimisation de la version imprimable par chapitre |
<font color=(?:([^> "]*)|"([^"]*)"|'([^']*)')>([^<]*)</font> ---> <span style="color:$1$2$3;">$4</span> + remplacement manuel " --> \" |
||
Ligne 60 :
table.insert(PrintVersion, frame:expandTemplate{ title = ':' .. fullPageName } .. '\n\n')
else
if debug then table.insert(PrintVersion, '<
end
end
Ligne 93 :
chapter = mw.ustring.gsub(chapter, "_", " ")
else
if debug then chapter = '<
end
Ligne 123 :
if chapter == BookName or chapter == BookName .. sep or mw.ustring.find(chapter, "%#") ~= nil then
if debug then chapter = '<
else
if OnlySubpages then
-- Book subpages only (and ignoring the other links like "see also")
if mw.ustring.find(chapter, BookName .. sep, 1, true) == nil then
if debug then chapter = "<
end
end
end
else
if debug then chapter = "<
end
return chapter
Ligne 213 :
fullPageName = p.getFullPageName(BookName, rawFullPageName)
if debug then
if mw.ustring.find(fullPageName, "<
fullPageName = nil
else
Ligne 231 :
if (subpageName ~= nil and subpageName ~= "") then
if found == true or homepage == true then
if debug then table.insert(footer, "<
if homepage == false then
Ligne 246 :
break
elseif subpageName == currentPageName then
if debug then table.insert(footer, "<
found = true
elseif fullPageName ~= "" then
Ligne 252 :
previousChapter = subpageName
else
if debug then table.insert(footer, "<
end
end
else
if debug then table.insert(footer, "<
end
end
Ligne 263 :
if found == true and table.getn(footer) == 0 then
if debug then table.insert(footer, "<
theTemplateLeft, nb = mw.ustring.gsub(templateLeft, "printf", BookName .. sep .. previousChapter .. "|" .. previousChapter)
table.insert(footer, theTemplateLeft)
|