Possible Duplicate:
CSS previous sibling selector
In a list, if there are 3 list items:
1 <li>..</li>
2 <li>..</li>
3 <li>..</li>
It is possible to use, for example li+li to get the one after the targeted list item.
My question: How to get the one BEFORE the targeted item?
$("#selected-li").prev("li").addClass("something");
– Bobby Stenly Feb 20 '12 at 01:39