﻿var bookmarkurl="http://www.kursy1x2.pl"
var bookmarktitle="Kursy 1X2 - Kursy Konfrontować"


	function bookmarkUs()
	{
		if (navigator.appName == 'Microsoft Internet Explorer' && parseInt(navigator.appVersion) >= 4)
		{
			window.external.AddFavorite(bookmarkurl,bookmarktitle);
		}
		else
		{
		var msg = "Remember to bookmark this page!";
		if(navigator.appName == "Netscape") 
			msg += "  (CTRL-D)";
		alert(msg);
		}
	}
	
	function GoToLeague()
	{
		var leagueID = document.getElementById('_ctl0_CP1_leaguesDD').value;
		if(leagueID==-1)
			return;
		location = 'LeagueGames.aspx?leagueID=' + leagueID;
	}
		 
	function LoadLeagues()
	{
        var formToSend = document.getElementById("aspnetForm");
        formToSend.submit();
	}
			 
	
	function OpenLink(bID, oID, oType)
	{
		window.open('openLink.aspx?bID=' + bID + '&oID=' + oID + '&oType=' + oType);
	}
	
	
	//used to move between next/today/tomorrow games	
	function GoToView(viewID)
	{
	    var elem = document.getElementById('_ctl0:CP1:iViewType');
		if(viewID<4)
		{
		    
			location = 'http://www.kursy1x2.pl/index.aspx?viewType=' + viewID;
		}
		else if(viewID==4)
		{
			location = 'valueBets.aspx';
		}
		else if(viewID==5)
		{
			location = 'sureBets.aspx';
		}
		else if(viewID==6)
		{
			location = 'OutrightOdds.aspx';
		}			
	}
	
	function GoToViewNotMain(viewID)
	{
		if(viewID<4)
		{
			location = 'index.aspx?viewType=' + viewID;
		}
		else if(viewID==4)
		{
			location = 'valueBets.aspx';
		}
		else if(viewID==5)
		{
			location = 'sureBets.aspx';
		}
		else if(viewID==6)
		{
			location = 'OutrightOdds.aspx';
		}					
	}		 	

