Difference between revisions of "Team:SDU-Denmark/Model"

Line 182: Line 182:
 
<!-- The Modal -->
 
<!-- The Modal -->
 
<div id="myModal" class="modal">
 
<div id="myModal" class="modal">
   <span class="close" id="closer">×</span>
+
   <span class="close">×</span>
 
   <img class="modal-content" id="img01">
 
   <img class="modal-content" id="img01">
 
   <div id="caption"></div>
 
   <div id="caption"></div>
Line 202: Line 202:
  
 
// Get the <span> element that closes the modal
 
// Get the <span> element that closes the modal
var span = document.getElementById("closer")[0];
+
var span = document.getElementsByClass("close")[0];
  
 
// When the user clicks on <span> (x), close the modal
 
// When the user clicks on <span> (x), close the modal

Revision as of 23:02, 18 October 2016

The Best


FIGURTEXT