var ct = document.URL.split("/");
	var sel_ct = ct[4];
$(document).ready(function() {
    $("#country").val(sel_ct);
	//alert(sel_ct);
});

function selCountry(oSelect)
{
	var target = oSelect.options[oSelect.selectedIndex].getAttribute("target");
	var url = oSelect.options[oSelect.selectedIndex].getAttribute("url");
	if(target != null && target == "newWindow")
		window.open(url,'_blank');
	else
		window.open(url,'_parent');
}


function country(){
	var ct = document.URL.split("/");
	var sel_ct = ct[4];
	//alert (ct[4]);
	setSelectedIndex(document.getElementById('country'),sel_ct);
}

function setSelectedIndex(s, v) {
    for ( var i = 0; i < s.options.length; i++ ) {
        if ( s.options[i].value == v ) {
            s.options[i].selected = true;
            return;
        }
    }
}

//code for- Video analatics -- Added on : 09/SEP/2011
$(window).unload(function() {
	var flashMovie=getFlashMovieObject("flvplayer_swf");
	if(flashMovie != null) flashMovie.closeVideoTracking();			
	});

	function getFlashMovieObject(movieName){
	if (window.document[movieName]){
		return window.document[movieName];
	}
	if (navigator.appName.indexOf("Microsoft Internet")==-1){
		if (document.embeds && document.embeds[movieName])
		return document.embeds[movieName];
	}
	else{
		return document.getElementById(movieName);
	}
}
