function showPeriod(index, nPeriods)
{
	if(index < 0) return;
	if(index >= nPeriods) return;
	for(var i=0; i<nPeriods; i++)
	{
		var titleId = 'period_title_' + i;
		var contentId = 'period_content_' + i;
		if(i == index)
		{
			showElement(titleId);
			showElement(contentId);
		}
		else
		{
			hideElement(titleId);
			hideElement(contentId);
		}
	}
}
function goToPeriod(cboId, move, formId)
{
	var cbo = document.getElementById(cboId);
	var newIndex = cbo.selectedIndex;
	var cboLen = cbo.length;
	if(move == 'prev')
	{
		newIndex--;
	}
	else
	{
		newIndex++;
	}
	if((newIndex < 0) || (newIndex > cboLen))
	{
		return;
	}
	cbo.selectedIndex = newIndex;
	goOn(formId);
}
function showPlayerPeriod(period_id)
{
	hideElement("plus_"+period_id);
	showElement("minus_"+period_id);
	showElement("period_"+period_id);
}
function hidePlayerPeriod(period_id)
{
	hideElement("minus_"+period_id);
	showElement("plus_"+period_id);
	hideElement("period_"+period_id);
}

function openCountryLink(oSelect)
{
	if(oSelect && (oSelect.value > 0))
	{
		var url = aCountriesUrls[oSelect.value];
		var name = aCountriesNames[oSelect.value];
		var width = 965;
		var height = 850;
		var fixX = 0;
		var fixY = 0;
		openPopupWindow(url,name,width,height,fixX,fixY);
	}
}
