Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

show hide div in javascript

<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
  </head>

  <body>
    <div id="box" style="background-color: salmon; width: 100px; height: 100px">
      Box 1
    </div>

    <button id="btn">Hide div</button>

    <script src="index.js"></script>
  </body>
</html>
Source by bobbyhadz.com #
 
PREVIOUS NEXT
Tagged: #show #hide #div #javascript
ADD COMMENT
Topic
Name
7+4 =