Modulo:Bozza: differenze tra le versioni
Contenuto cancellato Contenuto aggiunto
+ |
+ |
||
Riga 2:
local function removeFalsePositives(str)
return str:gsub('<!%-%-.-%-%->', ''):gsub('<nowiki>.-</nowiki>', '')
end
local function getPageContent()
local text = mw.title.getCurrentTitle():getContent() or ''
return removeFalsePositives(text)
end
function p.controllo_categorie(frame)
local text = getPageContent(
if text:find("%[%[%s*[Cc]ategoria%s*:%s*[^%s].-%]%]" ) then
return '[[Categoria:Bozze con categorie impreviste]]'
Riga 20 ⟶ 21:
function p.revisione_richiesta(frame)
local text = getPageContent()
local pattern = '%
return text:find(pattern) and 1 or ''
end
|