
// convert seconds to milliseconds
function ms( seconds )
{
  return seconds * 2000;  // 1000ms = 1s
}

// this is called as the browser reads the text from teh html page
// since this is before teh body tag no elements are loaded yet
//  use this line of code to execute ccode only after the document is loaded
$(document).ready(

  // pass in an anonymouse function to the $(document).ready()
  // it will execute this function when the document is loaded
  function()
  {		
    // access all element s with a class of "fade"
	  $('.innerfade').innerfade({
      speed: 4000,
      timeout: ms(5),
      type: 'sequence',
      containerheight: '190px'
    });
	}

  /*  Documentation
  $('ID or class of the element containing the fading objects').innerfade({
	  animationtype: Type of animation 'fade' or 'slide' (Default: 'fade'),
  	speed: Fadingspeed in milliseconds or keywords (slow, normal or fast)(Default: 'normal'),
	  timeout: Time between the fades in milliseconds (Default: '2000'),
  	type: Type of slideshow: 'sequence' or 'random' (Default: 'sequence'),
	  containerheight: Height of the containing element in any css-height-value (Default: 'auto')
  	runningclass: CSS-Class which the container get’s applied (Default: 'fade')
  });
  */

);


