I have two divs as follows:
<div class="car-service" id="browse-all-button">
<p>CAR SERVICE</p>
<span>56" Race Ramps</span>
<span>67" Race Ramps XTs</span>
<span>XTenders</span>
<span>40" Sport Ramps</span>
<span>Roll-Ups</span>
<span>Portable Pit Stop</span>
</div>
<div class="trailer-hauling" id="browse-all-button">
<p>TRAILER HAULING</p>
<span>56" Race Ramps</span>
<span>67" Race Ramps XTs</span>
<span>XTenders</span>
<span>40" Sport Ramps</span>
<span>Roll-Ups</span>
<span>Portable Pit Stop</span>
</div>
Jquery is a follows:
$(function(){
$('#browse-all-button').hover(function(){
$("p", this).stop().animate({textIndent:"25px", color:"#a12324"}, {duration:200});
alert($(this).attr("class"));
},
function(){
$("p", this).stop().animate({textIndent:"10px", color:"#424242"}, {duration:150})
})
} );
The Effect works on the first #browse-all-button, but not on the second. I have an alert in there to tell me what the current div class is, and it's not even triggered on the second div.
You can see it there by "browse all" and hovering over.
Thanks for any help!