// refresh main sport pages, excludes article page due to reading duration & video page

var timerId,bVidFlag;

if(JS_SUB_SECTION=='livescores')
{
	setRefresh(true)
}

function setRefresh(bVidFlag)
{
    var timeoutValue = 10 * 60 * 1000; //10 minutes
    if(JS_SUB_SECTIONID=='204279')//livescores on world cup
      timeoutValue = 2 * 60 * 1000; //2 minutes
    if(bVidFlag)
    {		
               if (window.location.href.indexOf("rf=true") > 0) 
		{
			timerId = window.setTimeout("window.location.href=window.location.href", timeoutValue);
		}
		else 
		{
			if (window.location.href.indexOf("?") > 0) 
			{
				timerId = window.setTimeout("window.location.href=window.location.href + '&rf=true';", timeoutValue);
			}
			else 
			{
				timerId = window.setTimeout("window.location.href=window.location.href + '?rf=true';", timeoutValue);
			}
		}		
    }
    else
    {
		if(!isNaN(parseInt(timerId))) {window.clearTimeout(timerId);}
    }
}












