jquery:simple pagination solution needed
<p>i have this code i cannt complete;</p>

<pre><code>&lt;div class=paginatme&gt;&lt;/div&gt;
&lt;div class=paginatme&gt;&lt;/div&gt;
&lt;div class=paginatme&gt;&lt;/div&gt;
&lt;div class=paginatme&gt;&lt;/div&gt;
&lt;div class=paginatme&gt;&lt;/div&gt;
&lt;div class=paginatme&gt;&lt;/div&gt;
&lt;div class=paginatme&gt;&lt;/div&gt;
&lt;div class=paginatme&gt;&lt;/div&gt;
&lt;div class=paginatme&gt;&lt;/div&gt;
&lt;input type=hidden value=1 id=current_shown onchange='functioN(this.value)'&gt;
&lt;a href=''&gt;Next&lt;/a&gt;&lt;a href=''&gt;previous&lt;/a&gt;
&lt;script&gt;
 functionN(x){
 ///CODE THAT SHOW div number X and 2 after and hide all..
 }
&lt;/script&gt;
</code></pre>

<p>i want to to add style=display:none to all and show them 3 by 3 on ahref click.</p>

<p>how can i count elements and give them style and none to rest ??</p>
