Hello.
How do I hide this div when I click outside it:
IneedittodisappearwhenIclickoutsideit.
Here'sasimilarexample:
$("body").on("click", function() {
$(".passageiros-div").slideUp("slow/400/fast");
});
.passageiros-div {
border: 1px solid #000;
}
<!DOCTYPE html>
<html>
<head>
<title>Teste</title>
</head>
<body>
<div class="passageiros-div">
<p>Titulo</p>
</div>
<div>
<h1>Frase de Teste</h1>
</div>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.0.1/jquery.min.js"></script>
</body>
</html>