Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

jquery check if clicked outside div

$(document).click(function() {
    alert('clicked outside');
});

$(".menuWraper").click(function(event) {
    alert('clicked inside');
    event.stopPropagation();
});
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #jquery #check #clicked #div
ADD COMMENT
Topic
Name
6+9 =