// JavaScript Document// Rollover images$(document).ready(function(){$("img.rolloverImage").hover( function() {  this.src = this.src.replace("_off","_on"); }, function() {  this.src = this.src.replace("_on","_off"); });});jQuery.preloadImages = function(){  for(var i = 0; i<arguments.length; i++)  {    jQuery("<img>").attr("src", arguments[i]);  }}$(document).ready(function(){$.preloadImages("images/register_btn1_on.gif", "images/login_btn1_on.gif", "images/grazing_refineSearch_updateBtn_on.jpg", "images/grazing_refineSearch_updateBtn_off.jpg", "images/livery_refineSearch_updateBtn_on.jpg", "images/grazing_searchBox_goBtn_on.jpg", "images/livery_searchBox_goBtn_on.jpg", "images/register_btn2_on.gif");});// Slideshowfunction slideSwitch() {    var $active = $('#headerSlideshowContent DIV.active');    if ( $active.length == 0 ) $active = $('#headerSlideshowContent DIV:last');    // use this to pull the divs in the order they appear in the markup    var $next =  $active.next().length ? $active.next()        : $('#headerSlideshowContent DIV:first');    // uncomment below to pull the divs randomly    // var $sibs  = $active.siblings();    // var rndNum = Math.floor(Math.random() * $sibs.length );    // var $next  = $( $sibs[ rndNum ] );    $active.addClass('last-active');    $next.css({opacity: 0.0})        .addClass('active')        .animate({opacity: 1.0}, 2000, function() {            $active.removeClass('active last-active');        });}$(function() {    setInterval( "slideSwitch()", 6000 );});// Site credit rollover$(document).ready(function(){	$("#siteCredit").hover( 		function(){ 			$("#siteCredit img.off").fadeTo("def", 0);			$("#siteCredit p").animate({ left: "10px"}, "fast" ); 			}, 		function(){ 			$("#siteCredit img.off").fadeTo("def", 1);			$("#siteCredit p").animate({ left: "100px"}, "fast" ); 		}	);});
