Cliquez sur la boîte à l'extérieur jQuery
$(document).click(function(){
$("#try").hide();
});
$("#try").click(function(e){
e.stopPropagation();
});
A D Bhowmick
$(document).click(function(){
$("#try").hide();
});
$("#try").click(function(e){
e.stopPropagation();
});
$(document).click(function() {
alert('clicked outside');
});
$(".menuWraper").click(function(event) {
alert('clicked inside');
event.stopPropagation();
});
$(document).click(function (event) {
var $target = $(event.target);
if (!$target.closest('.modal-dialog').length && $('.modal-dialog').is(":visible")) {
console.log("clicked outside the element")
}
});