Quantcast
Channel: BlogoSfera » hide
Viewing all articles
Browse latest Browse all 12

Click outside div to hide div in pure Javascript

$
0
0

I wrote this code but I can’t find how to make the div disappear if I click outside of it. I’m creating a popup that will appear once a button is clicked and disappear once the user clicks outside of the box. Please help. var popbox = document.getElementById("popbox"); document.getElementById("linkbox").onclick = function () { popbox.style.display = […]

The post Click outside div to hide div in pure Javascript appeared first on BlogoSfera.


Viewing all articles
Browse latest Browse all 12

Trending Articles