grabbing title with jquery
<p>Im trying to grab the "title" on the <code>&lt;li&gt;</code> when it is clicked. It keeps returning undefined.</p>

<p>html</p>

<pre><code>&lt;div id="sidebar"&gt;
        &lt;div class="navigation"&gt;
  &lt;ul&gt;

    &lt;li title="../../000_Movies/_assets/playlist.html"&gt;فیلم ها&lt;/li&gt;

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

<p>js</p>

<pre><code>$('.navigation li').click(function () {
$('.slider').animate({
    marginLeft: 0
}, 500,function() {
var test = $(this).attr('title');
alert(test);
  location.href = '';
});
});
</code></pre>
