Bioluminati (Talk | contribs) |
Bioluminati (Talk | contribs) |
||
Line 2: | Line 2: | ||
<!--------------------------> | <!--------------------------> | ||
− | |||
<html> | <html> | ||
<head> | <head> | ||
Line 35: | Line 34: | ||
<div id="overlay" onclick="off()"> | <div id="overlay" onclick="off()"> | ||
− | <div id="text"> | + | <div id="text">Overlay Text</div> |
+ | </div> | ||
+ | |||
+ | <div style="padding:20px"> | ||
+ | <h2>Overlay with Text</h2> | ||
+ | <button onclick="on()">Turn on overlay effect</button> | ||
</div> | </div> | ||
<script> | <script> | ||
+ | window.onload = function on() { | ||
+ | document.getElementById("overlay").style.display = "block"; | ||
+ | } | ||
function off() { | function off() { | ||
− | document.getElementById("overlay").style.display = " | + | document.getElementById("overlay").style.display = "none"; |
} | } | ||
</script> | </script> | ||
Line 47: | Line 54: | ||
</body> | </body> | ||
</html> | </html> | ||
+ | |||
<!-------------------------------> | <!-------------------------------> |
Revision as of 08:05, 6 December 2018