I have developed some code for image sliding in which whenever a mouse event occurs I want the id of the other div except on which the mouse is present.
My code is:
$('#div1,#div2,#div3,#div4,#div5,#div6').mouseover(function () {
$('#div1,#div2,#div3,#div4,#div5,#div6').css('width', '100px')
$("." + $(this).data('class')).animate({
'width':"400px",
}, {
'duration':1500,
easing:'easeOutBack',
})
});
thisis already the element you want, re-selecting it using itsidproperty makes no sense.