var group=new Array()
function setStyle(obj, cssClass){obj.className=cssClass; }
function redirect(x){
		var Obj;
		if (typeof(Prefix)!="undefined"){
			Obj = document.getElementById(Prefix + '_hdnDSP_KOD');
			document.getElementById(Prefix + '_hdnKTG_KOD').value="0";
		}
		temp.options.length = 0;
		for (i=0;i<group[x].length;i++){
		temp.options[i]=new Option(group[x][i].text,group[x][i].value)
		if(group[x][i].value==selectedValue) {
			if (typeof(Obj)!="undefined")
				Obj.value = x;
			temp.options[i].selected=true;
		}
	}
	if(selectedValue=="")
		temp.options[0].selected=true;
}
function setOverLinks ()
{
	for (i=1; i<9; i++)
	{
		var TDS = document.getElementById('Layer' + i).getElementsByTagName("td");
		for (j=0; j<TDS.length; j++)
		{
			if (TDS[j].className=='tdLink')
			{
				TDS[j].onmouseover = function(){ this.className='tdLinkH'; }
				TDS[j].onmouseout = function(){ this.className='tdLink'; }
			}
		}
	}
}
function ShowLayer(layerID){
	for (i=1; i<9; document.getElementById('Layer' + i).style.visibility=(layerID == ('Layer'+i))?"visible":"hidden",i++);
}
function ShowLayerP(layerID)
{
	if (layerID=='ic'){
		document.getElementById('ic').style.display = "block";
		document.getElementById('dis').style.display= "none";
	}
	else if (layerID=='dis'){
		document.getElementById('ic').style.display = "none";
		document.getElementById('dis').style.display= "block";
	}
}
function Yonlen( adres )
{
	window.location.href = adres;
}
function BolumSec(Sender)
{
	window.location.href = 'bolum.aspx?KOS_KOD=' + Sender.value;
}
function YazitipiSec(Sender)
{
	window.location.href = 'yazitipi.aspx?HTP_KOD=' + Sender.value;
}
function YazarSec(Sender)
{
	window.location.href = 'yazar.aspx?YZR_KOD=' + Sender.value;
}
function openWindow(lnk){
	window.open (lnk,"","height=600,width=583,scrollbars=yes,resizable=no,status=no,menubar=no,toolbar=no,location=no")
}
function MM_reloadPage(init) {  //reloads the window if Nav4 resized
  if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
    document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}
  else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();
}
MM_reloadPage(true);

function MM_findObj(n, d) { //v4.01
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}
function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}
function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}
function MM_preloadImages() { //v3.0
 var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
   var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
   if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}
function MM_showHideLayers() { //v6.0
  var i,p,v,obj,args=MM_showHideLayers.arguments;
  for (i=0; i<(args.length-2); i+=3) if ((obj=MM_findObj(args[i]))!=null) { v=args[i+2];
    if (obj.style) { obj=obj.style; v=(v=='show')?'visible':(v=='hide')?'hidden':v; }
    obj.visibility=v; }
}
function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}
function MM_jumpMenu(targ,selObj,restore){ //v3.0
  eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'");
  if (restore) selObj.selectedIndex=0;
}
ie4 = (document.all)? true:false

function toggle( targetId ){
 if (ie4){
    target = document.getElementById( targetId );
	target.style.display = (target.style.display == "none")?"":"none";
 }
}
function BoyutKontrol(_box)
{
	try
	{
		var HataMesaji = "";
		if (_box!=true) {
			if (CompareDates( IsDateC( 'txtHBR_TARIHILK') , IsDateC('txtHBR_TARIHSON') )>0)
				HataMesaji += 'Başlangıç tarihi bitiş tarihinden büyük olamaz.\n';
		}
		if (BoslukBuda((_box!=true)?'txtHBR_BASLIK':(Prefix+'_txtSearch')) != '')
			if (BoslukBuda((_box!=true)?'txtHBR_BASLIK':(Prefix+'_txtSearch')).length < 3)
				HataMesaji += 'Aranacak Kelimeyi 3 karakterden az girmeyiniz!';
		if (HataMesaji != "")
			return ShowError( HataMesaji );
		//execSearch(BoslukBuda((_box!=true)?'txtHBR_BASLIK':(Prefix+'_txtSearch')));
		return true;
	}
	catch(Hata) { return ShowError(Hata.description); }
}
function bizeUlasin(){
	MM_openBrWindow('bize_ulasin.aspx?URL=' + window.location.href.replace( /&/g, '*'),'Referans','width=350,height=507');
}

var finans;
function FinansOpen(_kod) {
	finans = window.open('http://www.bigpara.com/referans/popgrafik.asp?id=346&gr=' + _kod, 'popGrafik', 'toolbar=0,width=658,height=410,location=0,directories=0,status=0,menubar=0,scrollbars=0,resizable=0,copyhistory=0');
	finans.focus();
}

function setOpacity(obj, count){
	with (document.getElementById(obj).style){
		if (navigator.appVersion.indexOf("MSIE")<0) MozOpacity = (count/100);
		else filter = "alpha(opacity="+ count + ")";
	}
	if (count < 100)
		setTimeout('setOpacity("' + obj + '", ' + (count+=3) +  ' )', 10);
}
function execSearch(text) {
	var W, H;
	if (navigator.appVersion.indexOf("MSIE")<0)
	{ W = window.innerWidth; H = window.innerHeight; }
	else
	{ W = document.body.clientWidth; H=document.body.clientHeight; }
	document.body.innerHTML += "<div id=\"aramabox\" align=\"center\"></" + "div>";
	var aramabox = document.getElementById("aramabox");
	aramabox.innerHTML = "<iframe src=\"\" id=\"if1\" scrolling=\"no\" width=\"600px\" height=\"800px\"></" + "iframe>";
	var iframe = document.getElementById('if1');
	iframe.contentWindow.location = "search.aspx?TEXT=" + text;
	document.body.scrollTop = 0;
	with(aramabox.style) {
		left = '0px';
		top = '0px';
		width = W + 'px';
		height = H + 'px';
	}
	setOpacity('aramabox',1);
}
function openyardim() {
	if (finans)
		finans.close();
	finans = window.open('arsiv_yardim.html', 'yardim', 'width=520,scrollbars=yes,height=580');
	finans.focus();
}