// csociety index.html
// select random image
function rand ( n )
{
  return ( Math.floor ( Math.random ( ) * n + 1 ) );
}
// Store some random image URL's

var random_images = new Array ( );
random_images[0] = "../images/csociety/cs-birdwatch1.jpg";
random_images[1] = "../images/csociety/cs-birdwatch2.jpg";
random_images[2] = "../images/csociety/cs-birdwatch3.jpg";
random_images[3] = "../images/csociety/cs-egypt1.jpg";
random_images[4] = "../images/csociety/cs-egypt2.jpg";
random_images[5] = "../images/csociety/cs-egypt3.jpg";
random_images[6] = "../images/csociety/cs-egypt5.jpg";
// Pick a random image from the list,
// and set the image source to that image

function pick_image ( )
{
  document.getElementById("random-image").src = random_images[rand(7)-1];
}