<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="fr">
	<id>https://wikinabia.com/index.php?action=history&amp;feed=atom&amp;title=Module%3ASuppress_categories</id>
	<title>Module:Suppress categories - Historique des versions</title>
	<link rel="self" type="application/atom+xml" href="https://wikinabia.com/index.php?action=history&amp;feed=atom&amp;title=Module%3ASuppress_categories"/>
	<link rel="alternate" type="text/html" href="https://wikinabia.com/index.php?title=Module:Suppress_categories&amp;action=history"/>
	<updated>2026-04-23T23:32:42Z</updated>
	<subtitle>Historique des versions pour cette page sur le wiki</subtitle>
	<generator>MediaWiki 1.33.1</generator>
	<entry>
		<id>https://wikinabia.com/index.php?title=Module:Suppress_categories&amp;diff=5010&amp;oldid=prev</id>
		<title>Docteurmarty : 1 révision importée</title>
		<link rel="alternate" type="text/html" href="https://wikinabia.com/index.php?title=Module:Suppress_categories&amp;diff=5010&amp;oldid=prev"/>
		<updated>2019-10-08T05:37:19Z</updated>

		<summary type="html">&lt;p&gt;1 révision importée&lt;/p&gt;
&lt;table class=&quot;diff diff-contentalign-left&quot; data-mw=&quot;interface&quot;&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;fr&quot;&gt;
				&lt;td colspan=&quot;1&quot; style=&quot;background-color: #fff; color: #222; text-align: center;&quot;&gt;← Version précédente&lt;/td&gt;
				&lt;td colspan=&quot;1&quot; style=&quot;background-color: #fff; color: #222; text-align: center;&quot;&gt;Version du 8 octobre 2019 à 05:37&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-notice&quot; lang=&quot;fr&quot;&gt;&lt;div class=&quot;mw-diff-empty&quot;&gt;(Aucune différence)&lt;/div&gt;
&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;</summary>
		<author><name>Docteurmarty</name></author>
		
	</entry>
	<entry>
		<id>https://wikinabia.com/index.php?title=Module:Suppress_categories&amp;diff=5009&amp;oldid=prev</id>
		<title>fr&gt;Zebulon84 : A modifié le niveau de protection de « Module:Suppress categories » : Modèle très utilisé ([Modifier=Autoriser uniquement les utilisateurs autopatrolled] (infini) [Renommer=Autoriser uniquement les utilisateurs autopatrolled] (infini))</title>
		<link rel="alternate" type="text/html" href="https://wikinabia.com/index.php?title=Module:Suppress_categories&amp;diff=5009&amp;oldid=prev"/>
		<updated>2016-04-05T10:38:00Z</updated>

		<summary type="html">&lt;p&gt;A modifié le niveau de protection de « &lt;a href=&quot;/Module:Suppress_categories&quot; title=&quot;Module:Suppress categories&quot;&gt;Module:Suppress categories&lt;/a&gt; » : Modèle très utilisé ([Modifier=Autoriser uniquement les utilisateurs autopatrolled] (infini) [Renommer=Autoriser uniquement les utilisateurs autopatrolled] (infini))&lt;/p&gt;
&lt;p&gt;&lt;b&gt;Nouvelle page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;-- This is a simple module to strip categories from wikitext. It does&lt;br /&gt;
-- not support nested links or magic words like __TOC__, etc. Even so,&lt;br /&gt;
-- it should still handle most categories.&lt;br /&gt;
&lt;br /&gt;
local p = {}&lt;br /&gt;
&lt;br /&gt;
-- Detects if a category link is valid or not. If it is valid,&lt;br /&gt;
-- the function returns the blank string. If not, the input&lt;br /&gt;
-- is returned with no changes.&lt;br /&gt;
local function processCategory( all, submatch )&lt;br /&gt;
    local beforePipe = mw.ustring.match( submatch, '^(.-)[%s_]*|[%s_]*.-$' )&lt;br /&gt;
    beforePipe = beforePipe or submatch&lt;br /&gt;
    if mw.ustring.match( beforePipe, '[%[%]&amp;lt;&amp;gt;{}%c\n]' ) then&lt;br /&gt;
        return all&lt;br /&gt;
    else&lt;br /&gt;
        return ''&lt;br /&gt;
    end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
-- Preprocess the content if we aren't being called from #invoke,&lt;br /&gt;
-- and pass it to gsub to remove valid category links.&lt;br /&gt;
local function suppress( content, isPreprocessed )&lt;br /&gt;
    if not isPreprocessed then&lt;br /&gt;
        content = mw.getCurrentFrame():preprocess( content )&lt;br /&gt;
    end&lt;br /&gt;
    content = mw.ustring.gsub(&lt;br /&gt;
        content,&lt;br /&gt;
        '(%[%[[%s_]*[cC][aA][tT][eE][gG][oO][rR][yY][%s_]*:[%s_]*(.-)[%s_]*%]%])',&lt;br /&gt;
        processCategory&lt;br /&gt;
    )&lt;br /&gt;
    content = mw.ustring.gsub(&lt;br /&gt;
        content,&lt;br /&gt;
        '(%[%[[%s_]*[cC][aA][tT][éÉ][gG][oO][rR][iI][eE][%s_]*:[%s_]*(.-)[%s_]*%]%])',&lt;br /&gt;
        processCategory&lt;br /&gt;
    )&lt;br /&gt;
    return content&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
-- Get the content to suppress categories from, and find&lt;br /&gt;
-- whether the content has already been preprocessed. (If the&lt;br /&gt;
-- module is called from #invoke, it has been preprocessed already.)&lt;br /&gt;
function p.main( frame )&lt;br /&gt;
    local content, isPreprocessed&lt;br /&gt;
    if frame == mw.getCurrentFrame() then&lt;br /&gt;
        content = frame:getParent().args[1]&lt;br /&gt;
        if frame.args[1] then&lt;br /&gt;
            content = frame.args[1]&lt;br /&gt;
        end&lt;br /&gt;
        isPreprocessed = true&lt;br /&gt;
    else&lt;br /&gt;
        content = frame&lt;br /&gt;
        isPreprocessed = false&lt;br /&gt;
    end&lt;br /&gt;
    return suppress( content, isPreprocessed )&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
return p&lt;/div&gt;</summary>
		<author><name>fr&gt;Zebulon84</name></author>
		
	</entry>
</feed>