jquery - Inverse of Next Siblings Selector -


so came across next sibling selector on jquery docs today:

$("label + input") 

and wondering - there inverse of selector? i.e. select previous sibling?

i use:

$("label + input").prev() 

for example in this fiddle, labels in label followed input, want, way it?

you can use array provided sibling()

check out:

http://api.jquery.com/category/traversing/tree-traversal/


Comments

Popular posts from this blog

Unable to remove the www from url on https using .htaccess -