Can I work with the index value so easily? I think using the natural index values is better then using classes. I want to use the .index in that way.
Html
<div id="test">
<ul>
<li>Im index 0</li>
<li>Im index 1</li>
<li>Im index 2</li>
<li>Im index 3</li>
</ul>
</div>
Pseudo (Jquery) Javascript
$('#test ul > li').index(2).hide();
$('#test ul > li').index(1).click(function() {
alert('lulz you clicked the li with the index value of 1 bro');
});
I doesnt find a clue how to work this way with the .index value.. is it possible to work that easily with this method??