How do I get the index of a list item during a click even on that item?
<p>How do I get the index of a list item during a click even on that item?</p>

<pre><code>&lt;ul&gt;
    &lt;li&gt;&lt;/li&gt;
    &lt;li&gt;&lt;/li&gt;
    &lt;li&gt;&lt;/li&gt;
    &lt;li&gt;&lt;/li&gt;
    &lt;li&gt;&lt;/li&gt;
&lt;ul&gt;

$('li').live('click', function(e){
    alert(e.index);
})
</code></pre>

<p>Thanks</p>
