Page is a not externally linkable
- Code, Content, and Presentation
-- JavaScript and AJAX
---- jquery clickoutside event


enigma1 - 11:05 am on Apr 1, 2012 (gmt 0)


you hook the top html for the click event to close the menu
$('html').click(function(e) {
// Add conditionals and close menu here
});

and you prevent any event propagation of the menu container to the parent handlers so they're not notified since you handle clicks inside the menu container (so the previous code - above won't be informed to close whatever you need to close.
$('#menu').click(function(e) {
e.stopPropagation();
});


Thread source:: http://www.webmasterworld.com/javascript/4433171.htm
Brought to you by WebmasterWorld: http://www.webmasterworld.com