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">×</span>
+
   <span id="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.getElementsByClassName("close")[0];
+
var span = document.getElementsById("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 22:51, 18 October 2016

The Best


FIGURTEXT