Difference between revisions of "Team:NYU-AD"

Line 14: Line 14:
  
 
}
 
}
h2 {
+
.figure{
position:absolute;
+
position:relative;
top:650px;
+
width:90%;
left:100px;
+
 
width:100%;
+
margin:auto;
text-decoration: none;
+
padding:15px;
text-align:left;
+
padding-left:03%;
border:none;
+
padding-right:03%;
}
+
background:#F8F8F8;
h2 span {
+
border-style:solid;
  color: white;  
+
border-color:#3c948b;
  font: bold 24px/45px Helvetica, Sans-Serif;  
+
border-width:2px;
  letter-spacing: 1px;
+
border-radius:10px;
  background: rgb(0, 0, 0); /* fallback color */
+
  background: #397886;
+
  padding: 25px;  
+
 
}
 
}
</style>
 
  
 +
</style>
 +
<div class="figure">
 
<div onload = "startTimer()">
 
<div onload = "startTimer()">
 
<div class="RotateImg">
 
<div class="RotateImg">
 
<img id="theImage" src="https://static.igem.org/mediawiki/2015/b/bf/NYU_AD_GropuPhoto2.jpg" alt="" />
 
<img id="theImage" src="https://static.igem.org/mediawiki/2015/b/bf/NYU_AD_GropuPhoto2.jpg" alt="" />
<h2> <span>Self-sustaining Mosquito Trap </span></h2>
 
 
</div>
 
</div>
 
<button type="button" onclick="displayPreviousImage()">Previous</button>
 
<button type="button" onclick="displayPreviousImage()">Previous</button>
 
<button type="button" onclick="displayNextImage()">Next</button>
 
<button type="button" onclick="displayNextImage()">Next</button>
 
<br><br>
 
<br><br>
<p class="subtitle">Page Under Construction!<p>
+
</div>
 
+
 
</div>
 
</div>
 
</div>
 
</div>
Line 50: Line 46:
 
           function displayNextImage() {
 
           function displayNextImage() {
 
             console.log("Display next image");
 
             console.log("Display next image");
               x = (x === images.length - 1) ? 0 : x + 1;
+
               x = (x === images.length-1 ) ? 0 : x + 1;
 
               document.getElementById("theImage").src = images[x];
 
               document.getElementById("theImage").src = images[x];
 
           }
 
           }
Line 62: Line 58:
 
           function startTimer() {
 
           function startTimer() {
 
               console.log("Starting timer!");
 
               console.log("Starting timer!");
               setInterval(displayNextImage, 4000);
+
               setInterval(displayNextImage, 1000);
 
           }
 
           }
  
 
           var images = [], x = -1;   
 
           var images = [], x = -1;   
 
           images[0] = "https://static.igem.org/mediawiki/2015/2/2a/RotateImg2.jpg";
 
           images[0] = "https://static.igem.org/mediawiki/2015/2/2a/RotateImg2.jpg";
          images[1] = "https://static.igem.org/mediawiki/2015/1/17/RotateImg3.jpg";
+
images[1] = "https://static.igem.org/mediawiki/2015/b/bf/NYU_AD_GropuPhoto2.jpg";
           images[2] = "https://static.igem.org/mediawiki/2015/b/bf/NYU_AD_GropuPhoto2.jpg";
+
           images[2] = "https://static.igem.org/mediawiki/2015/1/17/RotateImg3.jpg";
 +
       
  
 
           console.log("Loaded!");
 
           console.log("Loaded!");

Revision as of 00:31, 18 September 2015