This code is taken from jQuery Docs.
HTML code. Note that I ve added classes for tabs.
<div id="tabs">
<ul>
<li class="tab1"><a href="#fragment-1"><span>One</span></a></li>
<li class="tab2"><a href="#fragment-2"><span>Two</span></a></li>
<li class="tab3"><a href="#fragment-3"><span>Three</span></a></li>
</ul>
<div id="fragment-1">
<p>First tab is active by default:</p>
<pre><code>$( #example ).tabs();</code></pre>
</div>
<div id="fragment-2">
Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat volutpat.
Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat volutpat.
</div>
<div id="fragment-3">
Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat volutpat.
Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat volutpat.
Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat volutpat.
</div>
</div>
Now, if you want to add multiple effects on tabs, all you have to do is the following:
$(document).ready(function(){
$("#tabs").tabs();
$("#tabs .tab1").click(function() { alert( hello world ); });
});
I ve not tested this, but I think it should work.