Difference between revisions of "Template:Newcastle/navbar2"

Line 116: Line 116:
 
}
 
}
  
.expand_btn:hover .navbar {
+
.expand_btn: {
     display: none;
+
     z-index: 101;
 +
    position: absolute;
 
}
 
}
  
  
 
</style>
 
</style>
 +
 +
<script>
 +
 +
function myFunction() {
 +
    var x = document.getElementById("navbar");
 +
    if (x.style.display === "none") {
 +
        x.style.display = "block";
 +
    } else {
 +
        x.style.display = "none";
 +
    }
 +
}
 +
 +
</script>
  
 
</head>
 
</head>
Line 214: Line 228:
  
 
</div>
 
</div>
<div class="expand_btn"><button>Expand</button></div>
+
<div class="expand_btn"><button onclick="myFunction()">Expand</button></div>
 
      
 
      
 
</body>
 
</body>
  
 
</html>
 
</html>

Revision as of 20:37, 16 October 2018