Ok, what I'm trying to figure out it how to use jQuery to work out which div
is currently selected, highlights, etc and then to apply code to that div
.
For example, I have three div
s lined up in a row. Each div
has a class
of .box
. Within each div
is another div
with a class of .overlay
. By default .overlay
is set to display: none;
, but when I roll the mouse over each div
I want to overlay for THAT div
ONLY to get set to become visible - all the other div
s overlay should remain hidden.
Take a look, http://jsfiddle.net/j76s2/
I've got the JS to get the overlay to show when the mouse rolls over the div
s, but it shows all the overlays whenever you roll the mouse over any div
. I know why that's happening but what I can't work out is how to get the code to work out that is should only show the overlay for the first div
when that div
has the mouse over it and so on.