title: rotating images in html
body: <p>hello everyone i'm trying to get these images to rotate every 5 seconds in HTML, using javascript. I cant figure out why images are not rotating, if someone could assist me that would be great!! thank you.</p>
  
  <pre><code>&lt;!DOCTYPE html&gt;
  &lt;html&gt;
  
  &lt;head&gt;
  
  &lt;title&gt;Concert Ads&lt;/title&gt;
  
  &lt;script type="text/javascript"&gt;
  
  var image1=new Image()
  image1.src="concert1.gif"
  
  var image2=new Image()
  image2.src="concert2.gif"
  
  var image3=new Image()
  image3.src="concert3.gif"
  
  var image4=new Image()
  image4.src="concert4.gif"
  
  var image5=new Image()
  image5.src="concert5.gif"
  
  
  &lt;/script&gt;
  
  &lt;/head&gt;
  
  &lt;body&gt;
  
  &lt;img src="concert1.gif" name="slide" &gt;
  
  &lt;script type="text/javascript"&gt;
  
  
  var step=1
  function slideit() { 
  document.images.slide.src=eval("image"+step+".src")
  
  if(step&lt;5)
  
  step++
  
  else
  
  step=1
  
  setTimeout("slideit()",5000)
  
  slideit()
  
  &lt;/script&gt;
  
  &lt;/body&gt;
  
  
  &lt;/html&gt;
  </code></pre>