javascript only - how to filter a specific div class?
<p>I have many DIVs, let's say 100, split by categories like that :</p>

<pre><code>&lt;div id="div1" class="cat01"&gt;text&lt;/div&gt;
&lt;div id="div2" class="cat02"&gt;text&lt;/div&gt;
&lt;div id="div3" class="cat01"&gt;text&lt;/div&gt;
&lt;div id="div4" class="cat02"&gt;text&lt;/div&gt;
&lt;div id="div5" class="cat03"&gt;text&lt;/div&gt;
&lt;div id="div6" class="cat01"&gt;text&lt;/div&gt;
</code></pre>

<p>And I want to filter a specific class<br>
Let's say I click on a button "filter only cat02"
I then have only this on the page : </p>

<pre><code>&lt;div id="div2" class="cat02"&gt;text&lt;/div&gt;
&lt;div id="div4" class="cat02"&gt;text&lt;/div&gt;
</code></pre>

<p>I do not have to use a class to define the categories, but it seems the appropriate solution...</p>

<p>Thanks you VERY much for your help!</p>

<hr>

<p><strong>EDIT</strong> : much clearer</p>

<p>Here is the file :</p>

<pre><code>&lt;div id="principal"&gt;
    &lt;div class="abc1 categ1"&gt;Text0&lt;/div&gt;
    &lt;div class="abc5 categ3"&gt;Text0&lt;/div&gt;
    &lt;div class="abc4 categ2"&gt;Text1&lt;/div&gt;
    &lt;div class="abc7 categ1"&gt;Text0&lt;/div&gt;
    &lt;div class="abc2 categ2"&gt;Text2&lt;/div&gt;
    &lt;div class="abc4 categ3"&gt;Text0&lt;/div&gt;
    &lt;div class="abc6 categ1"&gt;Text0&lt;/div&gt;
    &lt;div class="abc7 categ2"&gt;Text3&lt;/div&gt;
&lt;/div&gt;
</code></pre>

<p>and I want this :</p>

<pre><code>Text1
Text2
Text3
</code></pre>
