jQuery assign css class to divs in loop
<p>I have these html structure here,</p>

<pre><code>&lt;div class="myCaption"&gt;
 &lt;h2&gt;caption 1&lt;/h2&gt;
 &lt;h2&gt;caption 2&lt;/h2&gt;
 &lt;h2&gt;caption 3&lt;/h2&gt;
 &lt;h2&gt;caption 4&lt;/h2&gt;
 &lt;h2&gt;caption 5&lt;/h2&gt;
&lt;/div&gt;
</code></pre>

<p>I wonder how to use jquery to add a Class "active" to the first <strong>H2</strong> tag, and then every e.g, <strong>2 second</strong>, switch the "active" class from the first <strong>H2</strong> tag to the second <strong>H2</strong> tag and then to the third.....when come to the last H2 tag, it will loop again to the first <strong>H2</strong>, <strong>infinitely</strong>. Please advise. Thanks.</p>
