$(document).ready(function() 
    { 
        $("#myTable").tablesorter(); 
        changeCurrent(window.location);
		$('#menu').ptMenu();

	$('#target').fold();

	$("#redirect").click(function(){
		window.location = 'http://www.sports-1.com/oddsbay-free-bet.php';
	});

/*	var jS = $('#redirect');
// jS.hide(); // not needed if css hides elements initially
var i = 0;

function do_ticker(stop) {
  if(stop == "no"){
  jS.eq(i).fadeIn(800, function() {
    var me = $(this);     
    setTimeout(function() { me.hide(800, 
      function() { 
        i = ++i % jS.length;
        do_ticker("no");
      });
    },1000); // setTimeout
  });
  }
};
do_ticker("no");

$("#target").mouseover(function(){
		do_ticker("yes");
	});
*/
	
    } 
); 

function changeCurrent(strOption){
	if(strOption == "http://www.oddsbay.com/bookmakers/"){
		$("#odds").removeClass();
		$("#livescores").removeClass();
		$("#bookmakers").removeClass();
		$("#livescores").addClass("unactive");
		$("#odds").addClass("unactive");
		
		$("#bookmakers").addClass("current");
		
	}else if(strOption == "http://www.oddsbay.com/odds/"){
		$("#odds").removeClass();
		$("#livescores").removeClass();
		$("#bookmakers").removeClass();
		$("#livescores").addClass("unactive");
		$("#bookmakers").addClass("unactive");
		
		$("#odds").addClass("current");
		
	}else if(strOption == "http://www.oddsbay.com/livescores/"){
		$("#odds").removeClass();
		$("#livescores").removeClass();
		$("#bookmakers").removeClass();
		$("#odds").addClass("unactive");
		$("#bookmakers").addClass("unactive");
		
		$("#livescores").addClass("current");
		
	}
}
