// rotatePics.js

 var timeDelayPic = 3000;
 var pic_index    = 1;
 var max_num_pics = 34;
 var pic_num;
 var pic_str;

 function rotate_pic_start()
  {
  setTimeout( "rotate_pics()", timeDelayPic ); 
  }

 function rotate_pics()
  {
  // select a random image 
  pic_num = Math.round((max_num_pics*Math.random())+0.501);
  //pic_str = "images/common/rotates/pic_" + pic_num + ".jpg";
  pic_str = rotate_path + "pic_" + pic_num + ".jpg";
  //pic_str = "http://savethepoudre.org/images/common/rotates/pic_" + pic_num + ".jpg";
  document.img1.src=pic_str;

  // call rotate_pics() again after a delay
  setTimeout( "rotate_pics()", timeDelayPic ); 
  }
