var object;
var container;
var countryOn = 'selected';
var countryOff = 'deselected';

function setcountry(divId, containerId){

var countryList = new Array();

countryList[0] = '<a title="Belgium (French)" href="http://store.microsoft.com/default.aspx?store=FR&WT.mc_id=StoreCountryToggle_BE" target="_parent">Belgium (French)</a>';
countryList[1] = '<a title="Belgium (Dutch)" href="http://store.microsoft.com/default.aspx?store=NL&WT.mc_id=StoreCountryToggle_BE" target="_parent">Belgium (Dutch)</a>';
countryList[2] = '<a title="Deutschland" href="http://store.microsoft.com/default.aspx?store=DE&WT.mc_id=StoreCountryToggle_DE" target="_parent">Deutschland</a>';
countryList[3] = '<a title="Espa&ntilde;a" href="http://store.microsoft.com/default.aspx?store=ES&WT.mc_id=StoreCountryToggle_ES" target="_parent">Espa&ntilde;a</a>';
countryList[4] = '<a title="France" href="http://store.microsoft.com/default.aspx?store=FR&WT.mc_id=StoreCountryToggle_FR" target="_parent">France</a>';
countryList[5] = '<a title="Nederland" href="http://store.microsoft.com/default.aspx?store=NL&WT.mc_id=StoreCountryToggle_NL" target="_parent">Nederland</a>';
countryList[6] = '<a title="Österreich" href="http://store.microsoft.com/default.aspx?store=DE&WT.mc_id=StoreCountryToggle_AT" target="_parent">Österreich</a>';
countryList[7] = '<a title="United Kingdom" href="http://store.microsoft.com/default.aspx?store=UK&WT.mc_id=StoreCountryToggle_UK" target="_parent">United Kingdom</a>';
countryList[8] = '<a title="United States" href="http://store.microsoft.com/default.aspx?store=US&WT.mc_id=StoreCountryToggle_US" target="_parent">United States</a>';
countryList[9] = '<a title="日本" href="http://store.microsoft.com/default.aspx?store=JP&WT.mc_id=StoreCountryToggle_JP" target="_parent">日本</a>';
countryList[10] = '<a title="대한민국" href="http://store.microsoft.com/default.aspx?store=KR&WT.mc_id=206" target="_parent">대한민국</a>';

var countryFinal = '';

object = document.getElementById(divId);
container = document.getElementById(containerId);

for (i=0;i<countryList.length;i++)
{
	countryFinal += "<li>" + countryList[i] + "</li>";
}

object.innerHTML = countryFinal;
object.style.display = "block";
container.className=countryOn;
}

function showcountry(divId){
    if (object != null)
	{
		object.style.display = "block";
		container.className=countryOn;
	}
}

function hidecountry(divId){
    if (object != null)
	{
		object.style.display = "none";
		container.className=countryOff;
	}
}
