/    Sign up×
Community /Pin to ProfileBookmark

Nested Div calls onmouseout of parent, y?

I’m wondering if anyone can provide some insight on the onmouseover and onmouseout beahviours when it comes to using them with divs.

Right now I’m playing around and have created a smaller div nested inside another larger div. The nested div and container both have onmouse events written in the div tags – ie <div onmouseout=”javascript:function()”

What seems to happen though, which I wish wouldnt happen, is that when i mouse over the nested div, the container div onmouseout is called. Is this a browser specific thing and is there anyway to avoid this so that when im on the nested div, the parent div doesnt call the onmouseout event?

to post a comment
CSS

1 Comments(s)

Copy linkTweet thisAlerts:
@KDLAApr 08.2008 — What sort of function are you calling? It could be that there is an alternative way to do this, through either CSS :hover or restructuring your HTML.
×

Success!

Help @plazma1 spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 6.17,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @nearjob,
tipped: article
amount: 1000 SATS,

tipper: @meenaratha,
tipped: article
amount: 1000 SATS,

tipper: @meenaratha,
tipped: article
amount: 1000 SATS,
)...