var params = {};
			params.bgcolor = "#ffffff";
			var attributes = {};

			var flashvars1 = {};
			var params1 = {};
			params1.bgcolor = "#ffffff";
			//System.useCodePage=true;
			flashvars1.xmlPath = "xml/xmldeneme.php?<?=md5(uniqid(time()));?>";
			swfobject.embedSWF("preview.swf", "content2", "675", "255", "9.0.0", "expressInstall.swf", flashvars1, params1, attributes);


function openPopUp_comment(href, target)
{
	window.open(href, target, 'width=568, height=400, top=0, toolbar=0, location=0, directories=0, status=1, menuBar=0, scrollBars=1, resizable=0');
	return false;
}

function mostlyPage(type, page)
{
    mostly_type = type;
	var xmlHttpReq = false;
    var self = this;
    var strURL = 'x_mostly.php?type=' + type + '&page=' + page;

    if (window.XMLHttpRequest)
    {
        self.xmlHttpReq = new XMLHttpRequest();
    }
    else if (window.ActiveXObject)
    {
        self.xmlHttpReq = new ActiveXObject("Microsoft.XMLHTTP");
    }

    self.xmlHttpReq.open('GET', strURL, true);
    self.xmlHttpReq.setRequestHeader('Content-Type', 'application/x-javascript; charset=utf-8');
    self.xmlHttpReq.onreadystatechange = function()
    {
        if (self.xmlHttpReq.readyState == 4)
        {
        	mostlyLoad(type, self.xmlHttpReq.responseText);
        }
    }
    self.xmlHttpReq.send('');
    return false;
}
function mostlyLoad(type, str)
{
	eval(str);

	document.getElementById("mostly_items_data_" + type).innerHTML = mostly_items;
	changeMostly(type, 0);
}
function changeMostly(type, idx, link)
{
	eval('elm = mostly_data_' + type);

	if(typeof(window['elm']) == "undefined")
		return;

	document.getElementById("mostly_image_" + type).innerHTML = '<a target="_self" href="news_detail.php?id=' + idx + '">' + elm[idx]['image'] + '</a>';
	document.getElementById("mostly_title_" + type).innerHTML = '<a target="_self" href="news_detail.php?id=' + idx + '">' + elm[idx]['title'] + '</a>';
	document.getElementById("mostly_short_content_" + type).innerHTML = '<a target="_self" href="news_detail.php?id=' + idx + '">' + elm[idx]['short_content'] + '</a>';

}

function changeVideo(type, idx)
{
	eval('elm = video_data_' + type);

	if(typeof(window['elm']) == "undefined")
	return;
	document.getElementById("video_image_" + type).innerHTML = '<a target="_blank" href="video.php?vid=' + idx + '">' + elm[idx]['image'] + '</a>';
	document.getElementById("video_image2_" + type).innerHTML = '<a target="_blank" href="video.php?vid=' + idx + '">' + elm[idx]['image2'] + '</a>';
}


function changeBlack(type, idx)
{
	eval('elm = black_data_' + type);

	if(typeof(window['elm']) == "undefined")
	return;

	document.getElementById("black_image_" + type).innerHTML = '<a target="_self" href="news_detail.php?id=' + idx + '">' + elm[idx]['image'] + '</a>';
}


function changeAuthor(type, idx, link)
{
	eval('elm = author_data_' + type);

	if(typeof(window['elm']) == "undefined")
		return;

	document.getElementById("author_image_" + type).innerHTML = '<a target="_self" href="article_detail.php?id=' + idx + '">' + elm[idx]['image'] + '</a>';
	document.getElementById("author_title_" + type).innerHTML = '<a target="_self" class="link_baslik_koseyazisi" href="article_detail.php?id=' + idx + '">' + elm[idx]['title'] + '</a>';
}

function popup_url(url) 
{
	window.open(url, '', '');
}
