+ 3
Manipulating some items in the selected class in jquery
hi! how can i set values of some elements for e.g i have 9 div and i want to access some of those div using jquery how can i do that when i do like this it gives error $('div)[x].css("backgroundColor", "#fff");
3 ответов
+ 2
$("div:eq(2)").css("backgroundColor","#fff"); //selects 3rd div element
0
thanks! but can you suggest what should be the correct syntax if i want to access x nbr div