Created
March 20, 2017 13:17
-
-
Save mo7amd/08ca0f635bc110120b71e7ad03e161f3 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$('child').hide(); | |
$('parent').mouseover(function(){ | |
$(this).find('child').show(); | |
anchor_hover(); | |
}).mouseout(function(){ | |
anchor_hover(); | |
$(this).find('child').hide(); | |
}); | |
function anchor_hover() { | |
$('child').mouseover(function() { | |
$(this).next('parent').show(); | |
}).mouseout(function() { | |
$('child').hide(); | |
}); | |
} | |
// ******************************************** | |
//**************** html structure ************************ | |
<ul> | |
<li (parent)> | |
<div (child)> | |
</div> | |
</li> | |
</ul> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment