function nesneyarat()
{
	var nesne;
	if(navigator.appName=="Microsoft Internet Explorer")
	nesne=new ActiveXObject("Microsoft.XMLHTTP");
	else
	nesne=new XMLHttpRequest();	
	return nesne;
}
var http=nesneyarat();

var gnesne;
function ybbilgi(nesne)
{
	gnesne=nesne;
	if(nesne.name!="")
	{
		document.getElementById('altyer').style.top=gnesne.offsetTop+gnesne.offsetParent.offsetTop+gnesne.offsetParent.offsetParent.offsetTop+180;
		document.getElementById('altyer').style.left=gnesne.offsetLeft+gnesne.offsetParent.offsetLeft+gnesne.offsetParent.offsetParent.offsetLeft;
		document.getElementById('altyer').innerHTML="<Table bgcolor=#FFFFCC border=1 cellpadding=2 cellspacing=0 rules=groups style=\"border-collapse: collapse\">"+nesne.name+"</Table>";
		return;
	}
	http.open('get','ajaxbilgi.php?gno='+encodeURI(nesne.id));
	http.onreadystatechange=cevapFonksiyonu;
	http.send(null);	
}

function cevapFonksiyonu()
{
	if(http.readyState==4)
	{
		document.getElementById('altyer').style.top=gnesne.offsetTop+gnesne.offsetParent.offsetTop+gnesne.offsetParent.offsetParent.offsetTop+140+gnesne.offsetParent.offsetHeight;
		document.getElementById('altyer').style.left=gnesne.offsetLeft+gnesne.offsetParent.offsetLeft+gnesne.offsetParent.offsetParent.offsetLeft;
		document.getElementById('altyer').innerHTML="<Table bgcolor=#FFFFCC border=1 cellpadding=2 cellspacing=0 rules=groups style=\"border-collapse: collapse\">"+http.responseText+"</Table>";
		document.getElementById(gnesne.id).name=decodeURI(http.responseText);	
	}
}

function yertemizle()
{
	document.getElementById('altyer').innerHTML="";
}

//yazılı basın arşiv raporu
function ybar(vd,stxcmcikti,pdfcikti)
{
	//gno,yayintarihi,yayin,il,tiraj,baslik,sayfano,topalan,kayitturu,ceviri,pdfcikti
	var kt=new Array("","Haber","Reklam","Sponsorluk","RİR");	
	for(x=0; x<vd.length; x++)
	{
		document.write("<tr OnMouseOver=\"this.bgColor='#E0E0E0'\" OnMouseOut=\"this.bgColor='#ffffff'\">");
		document.write("<td>"+(x+1)+"</td>");
		document.write("<td>"+vd[x][1]+"</td>");
		document.write("<td>"+vd[x][2]+"</td>");
		document.write("<td>"+vd[x][3]+"</td>");
		document.write("<td align=right>"+vd[x][4]+"</td>");
		document.write("<td>"+(vd[x][9]==1?"<img src='trans.gif'> ":"")+"<a href=\"javascript:kac('yb_kupurgoster.php?gno="+vd[x][0]+"')\" id='"+vd[x][0]+"' OnMouseOver=\"ybbilgi(this);\" OnMouseOut=\"yertemizle();\">"+vd[x][5]+"</a></td>");
		document.write("<td>"+vd[x][6]+"</td>");
		if(stxcmcikti)
		document.write("<td>"+vd[x][7]+"</td>");
		document.write("<td>"+kt[vd[x][8]]+"</td>");
		document.write("<td align=center><INPUT TYPE=checkbox NAME='secim' class=checkbox id='"+vd[x][0]+"' value='"+(pdfcikti==1?(vd[x][10]==1?"1":"0"):"0")+"'></td>");
		if(pdfcikti==1)
		document.write("<td align=center>"+(vd[x][10]==1?"<img src='pdf1.gif'>":"")+"</td>");
		document.write("</tr>");
	}
}

function ybtamlist(vd,tks)
{
	//gno,yayintarihi,yayin,il,tiraj,baslik,sayfano,kayitturu,ceviri,kayitno,etarih
	var kt=new Array("","Haber","Reklam","Sponsorluk","RİR");	
	for(x=0; x<vd.length; x++)
	{
		document.write("<tr OnMouseOver=\"this.bgColor='#E0E0E0'\" OnMouseOut=\"this.bgColor='#ffffff'\">");
		document.write("<td>"+(tks-x)+"</td>");
		document.write("<td>"+vd[x][1]+"</td>");
		document.write("<td>"+vd[x][2]+"</td>");
		document.write("<td>"+vd[x][3]+"</td>");
		document.write("<td align=right>"+vd[x][4]+"</td>");
		document.write("<td>"+(vd[x][8]==1?"<img src='trans.gif'> ":"")+"<a href=\"javascript:kac('yb_kupurgoster.php?gno="+vd[x][0]+"')\" id='"+vd[x][0]+"' OnMouseOver=\"ybbilgi(this);\" OnMouseOut=\"yertemizle();\">"+vd[x][5]+"</a></td>");
		document.write("<td>"+vd[x][6]+"</td>");
		document.write("<td>"+kt[vd[x][7]]+"</td>");
		document.write("<td>"+vd[x][9]+"</td>");
		document.write("<td align=center><INPUT TYPE=checkbox NAME='secim' class=checkbox id='"+vd[x][0]+"'></td>");
		document.write("</tr>");
	}
}

//görsel basın arşiv raporu
function gbar(vd)
{
	//gno,kayittarihi,yayin,program,aciklama,kayitsaati,kayitsuresi,kayitturu,ceviri,klip
	var kt=new Array("","Haber","Reklam","Sponsorluk","RİR");	
	for(x=0; x<vd.length; x++)
	{
		document.write("<tr OnMouseOver=\"this.bgColor='#E0E0E0'\" OnMouseOut=\"this.bgColor='#ffffff'\">");
		document.write("<td>"+(x+1)+"</td>");
		document.write("<td>"+vd[x][1]+"</td>");
		document.write("<td>"+vd[x][2]+"</td>");
		document.write("<td>"+vd[x][3]+"</td>");
		document.write("<td>"+(vd[x][8]==1?"<a href='gb_cevirigoster.php?gno="+vd[x][0]+"' onclick=\"yenipencere(this.href,'gbceviri',350,200);return false\"><img src='trans.gif' border=0></a>&nbsp;":"")+vd[x][4]+"</td>");
		document.write("<td>"+vd[x][5]+"</td>");
		document.write("<td>"+vd[x][6]+"</td>");
		document.write("<td>"+kt[vd[x][7]]+"</td>");
		document.write("<td align=center>"+(vd[x][9]==1?"<a href='gb_videooynat.php?gno="+vd[x][0]+"' onclick=\"yenipencere(this.href,'gbvideo',550,550);return false\">İZLE</a>":"")+"</td>");
		document.write("<td align=center><INPUT TYPE=checkbox NAME='secim' class=checkbox id='"+vd[x][0]+"'></td>");
		document.write("</tr>");
	}
}

//radyo arşiv raporu
function rdar(vd)
{
	//gno,kayittarihi,yayin,program,aciklama,kayitsaati,kayitsuresi,kayitturu,ceviri,secim,klip
	var kt=new Array("","Haber","Reklam","Sponsorluk","RİR");	
	for(x=0; x<vd.length; x++)
	{
		document.write("<tr OnMouseOver=\"this.bgColor='#E0E0E0'\" OnMouseOut=\"this.bgColor='#ffffff'\">");
		document.write("<td>"+(x+1)+"</td>");
		document.write("<td>"+vd[x][1]+"</td>");
		document.write("<td>"+vd[x][2]+"</td>");
		document.write("<td>"+vd[x][3]+"</td>");
		//çeviri
		document.write("<td>"+(vd[x][8]==1?"<a href='rd_cevirigoster.php?gno="+vd[x][0]+"' onclick=\"yenipencere(this.href,'rdceviri',350,200);return false\"><img src='trans.gif' border=0></a>&nbsp;":"")+vd[x][4]+"</td>");
		document.write("<td>"+vd[x][5]+"</td>");
		document.write("<td>"+vd[x][6]+"</td>");
		document.write("<td>"+kt[vd[x][7]]+"</td>");
		//izleme
		document.write("<td align=center>"+(vd[x][10]==1?"<a href='rd_oynat.php?gno="+vd[x][0]+"' onclick=\"yenipencere(this.href,'rdklip',550,550);return false\">İZLE</a>":"")+"</td>");
		//seçim
		document.write("<td align=center>");
		if(vd[x][9]==-1)//kayıt haber değil
		;
		else if(vd[x][9]==0)//seçilmemiş
		document.write("<INPUT TYPE=checkbox NAME='secim["+x+"]' class=checkbox value="+vd[x][0]+">");
		else if(vd[x][9]==1)//seçilmiş
		document.write("<a href='rd_haberistek.php?cikar="+vd[x][0]+"' class=link2><IMG SRC='cikar.gif' WIDTH=16 HEIGHT=16 BORDER=0></a>");
		document.write("</td>");
		document.write("</tr>");
	}
}

//elektronik basın arşiv raporu
function ebar(vd)
{
	//gno,yayintarihi,yayin,baslik,kayitturu
	var kt=new Array("","Haber","Reklam","Sponsorluk","RİR");	
	for(x=0; x<vd.length; x++)
	{
		document.write("<tr OnMouseOver=\"this.bgColor='#E0E0E0'\" OnMouseOut=\"this.bgColor='#ffffff'\">");
		document.write("<td>"+(x+1)+"</td>");
		document.write("<td>"+vd[x][1]+"</td>");
		document.write("<td>"+vd[x][2]+"</td>");
		document.write("<td><a href=\"javascript:kac('eb_kupurgoster.php?gno="+vd[x][0]+"')\">"+vd[x][3]+"</a></td>");
		document.write("<td>"+kt[vd[x][4]]+"</td>");
		document.write("<td align=center><INPUT TYPE=checkbox NAME='secim' class=checkbox id='"+vd[x][0]+"'></td>");
		document.write("</tr>");
	}
}

//haber ajansı arşiv raporu
function haar(vd,oa,de)
{
	//gno,yayintarihi,yayin,baslik
	for(x=0; x<vd.length; x++)
	{
		document.write("<tr OnMouseOver=\"this.bgColor='#E0E0E0'\" OnMouseOut=\"this.bgColor='#ffffff'\">");
		//özel arşiv
		if(oa==1)
		document.write("<td><a href=ha_ozelarsiveekle.php?gno="+vd[x][0]+" onclick=\"yenipencere(this.href,'ozelarsiv',250,70);return false\">"+de+"</a></td>");
		document.write("<td>"+(x+1)+"</td>");
		document.write("<td>"+vd[x][1]+"</td>");
		document.write("<td>"+vd[x][2]+"</td>");
		document.write("<td><a href='ha_kupurgoster.php?gno="+vd[x][0]+"'>"+vd[x][3]+"</a></td>");
		document.write("</tr>");
	}
}

//tarih verisi yazılıyor
function gunayekle(fadi,gun,ay,yil,bayil,biyil)
{
	document.write("<select name="+fadi+"gun class=combobox>");
	for(sa=1; sa<32; sa++)
	{
		sec="",est="";
		if(sa==gun)
		sec=" selected";
		if(sa<10)
		est="0";
		document.write("<option value="+est+sa+sec+">"+est+sa+"</option>");
	}
	document.write("</select>");

	document.write("<select name="+fadi+"ay class=combobox>");
	for(sa=1; sa<13; sa++)
	{
		sec="",est="";
		if(sa==ay)
		sec=" selected";
		if(sa<10)
		est="0";

		document.write("<option value="+est+sa+sec+">"+est+sa+"</option>");
	}
	document.write("</select>");

	document.write("<select name="+fadi+"yil class=combobox>");
	for(sa=bayil; sa<=biyil; sa++)
	{
		sec="";
		if(sa==yil)
		sec=" selected";
		document.write("<option value="+sa+sec+">"+sa+"</option>");
	}
	document.write("</select>");
}


function ustekle(b,t)
{

document.write("<TABLE cellpadding=0 cellspacing=0 bgcolor=#12437C width=100% height=112>");

document.write("<TR valign=top>");
document.write("<TD WIDTH=300><IMG SRC='mtmlogo.jpg' WIDTH=300 HEIGHT=112></TD>");
document.write("<TD><TABLE height=\"100%\" cellpadding=0 cellspacing=0 width=100%><TR valign=bottom><TD align=right><Font style=\"color: #FFFFFF; font-weight: bold; FONT-FAMILY: Arial; FONT-SIZE: 16px;\">medya elinizin altında...&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<BR><BR></Font></TD></TR></TABLE></TD>");
document.write("<TD WIDTH=200><TABLE cellpadding=0 cellspacing=0 width=100% height=100% border=0 valign=top><TR height=30><TD align=right><Font style=\"color: #FFFFFF; font-weight: bold; FONT-FAMILY: Arial; FONT-SIZE: 14px;\">"+t+"</Font>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD></TR><TR><TD></TD></TR></TABLE></TD>");
document.write("</TR>");

document.write("<TR height=3><TD colspan=2 bgcolor=#FFFFFF></TD><TD></TD></TR>");

document.write("<TR height=26><TD colspan=2 bgcolor=#444450 background='ustmenubg.jpg'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;");
document.write("<a href='yb_index.php' class="+(b==1?"auma":"aumb")+">yazılı basın takibi</a> | <a href='eb_index.php' class="+(b==4?"auma":"aumb")+">e-basın takibi</a> | <a href='gb_index.php' class="+(b==2?"auma":"aumb")+">görsel basın takibi</a> | <a href='rd_index.php' class="+(b==3?"auma":"aumb")+">işitsel basın takibi</a> | <a href='ha_index.php' class="+(b==5?"auma":"aumb")+">haber ajansları takibi</a>");
document.write("</TD><TD></TD></TR>");

document.write("</TABLE>");
}

function sagekle(b,mam,ah,altmenu)//bölüm, medyararma motoru, ajanshaberleri
{
	if(navigator.appName=="Microsoft Internet Explorer")
	document.write("<div id='Layer1' style=\"position:relative; width: 0px;	height: 0px; z-index: 1; left: -66px; top: -110px;\"><img src='ustresim.png' width=160 height=160></div><div id='Layer1' style=\"position:relative; width: 0px; height: 0px; z-index: 1; left: 0px; top: -100px;\">");
	else if(navigator.appName=="Opera")
	document.write("<div id='Layer1' style=\"position:relative; width: 0px;	height: 0px; z-index: 1; left: -226px; top: -110px;\"><img src='ustresim.png' width=160 height=160></div><div id='Layer1' style=\"position:relative; width: 0px;	height: 0px; z-index: 1; left: -168px; top: -100px;\">");
	else//firefox vb.
	document.write("<div id='Layer1' style=\"position:relative; width: 0px;	height: 0px; z-index: 1; left: -226px; top: -110px;\"><img src='ustresim.png' width=160 height=160></div><div id='Layer1' style=\"position:relative; width: 0px;	height: 0px; z-index: 1; left: -168px; top: 60px;\">");

	document.write("<TABLE cellpadding=0 cellspacing=0 width=168 border=0>");
	document.write("<TR height=24><TD background=\"solmenubg.jpg\">&nbsp;&nbsp;&nbsp;<a href='koseyazarlari.php' class="+(b==6?"auma":"aumb")+">köşe yazarları</a></TD></TR>");
	document.write("<TR height=24><TD background=\"solmenubg.jpg\">&nbsp;&nbsp;&nbsp;<a href='yayinsayfalari.php' class="+(b==7?"auma":"aumb")+">günlük gazeteler</a></TD></TR>");
	document.write("<TR height=24><TD background=\"solmenubg.jpg\">&nbsp;&nbsp;&nbsp;<a href='tvbrowser.php' class="+(b==12?"auma":"aumb")+">tv yayınları<IMG SRC='yeni.gif' WIDTH=24 HEIGHT=14 BORDER=0></a></TD></TR>");
	if(mam)
	document.write("<TR height=24><TD background=\"solmenubg.jpg\">&nbsp;&nbsp;&nbsp;<a href='medyaaramamotoru.php' class="+(b==8?"auma":"aumb")+">medya arama motoru</a></TD></TR>");
	if(ah)
	document.write("<TR height=24><TD background=\"solmenubg.jpg\">&nbsp;&nbsp;&nbsp;<a href='ajanshaberleri.php' class="+(b==9?"auma":"aumb")+">ajans haberleri</a></TD></TR>");
	document.write("<TR height=24><TD background=\"solmenubg.jpg\">&nbsp;&nbsp;&nbsp;<a href='gundem.php' class="+(b==10?"auma":"aumb")+">medya gündemi<IMG SRC='yeni.gif' WIDTH=24 HEIGHT=14 BORDER=0></a></TD></TR>");
	document.write("<TR height=24><TD background=\"solmenubg.jpg\">&nbsp;&nbsp;&nbsp;<a href='haberozetleri.php' class="+(b==11?"auma":"aumb")+">haber özetleri<IMG SRC='yeni.gif' WIDTH=24 HEIGHT=14 BORDER=0></a></TD></TR>");
	document.write("<TR><TD><IMG SRC='solmenures.jpg' WIDTH=160 HEIGHT=35></TD></TR>");
	document.write("</TABLE><BR>");
	document.write(altmenu);
	document.write("</div>");
}

//sayfanın alt bölümünü ekler
function altekle()
{	
	document.write("<TABLE width='100%'><TR><TD align=center>&nbsp;&nbsp;<a href='../' class=aboutlink1><B>MTM MEDYA TAKİP MERKEZİ</B></a>&nbsp;&nbsp;İstanbul Merkez: <B>0212 442 20 82</B>&nbsp;&nbsp;Ankara Şube: <B>0312 427 89 89</B>&nbsp;&nbsp;Avrupa Şube: <B>(+49) 08207.963581</B>&nbsp;&nbsp;E-Mail: <B><a class=aboutlink1 href='mailto:info@medyatakip.com'>info@medyatakip.com</a></B></TD></TR></TABLE>");
}


//zaman aralığı kısıtlama uyarısı
function onayla()
{
	//basın içeriği seçildi mi
	if(typeof(document.arama.basinicerigi)!='undefined' && document.arama.basinicerigi.value<0)
	{
		alert("Basın içeriğini lütfen seçiniz.");
		document.arama.basinicerigi.focus();
		return false;
	}

	var bast = new Date(parseInt(document.arama.takvim1.value.substring(6,10),10),parseInt(document.arama.takvim1.value.substring(3,5),10)-1,parseInt(document.arama.takvim1.value.substring(0,2),10)); 
	var bitt = new Date(parseInt(document.arama.takvim2.value.substring(6,10),10),parseInt(document.arama.takvim2.value.substring(3,5),10)-1,parseInt(document.arama.takvim2.value.substring(0,2),10)); 

	if(bast>bitt)
	{
		alert("Başlangıç tarihi, bitiş tarihinden büyük olmamalıdır.");
		return false;
	}

	var tt = new Date(parseInt(document.arama.takvim1.value.substring(6,10),10)+1,parseInt(document.arama.takvim1.value.substring(3,5),10)-1,parseInt(document.arama.takvim1.value.substring(0,2),10)); 

	if(tt<bitt)
	{
		alert("Lütfen aramalarınızı maksimum 1 yıl tarih aralıklarıyla yapınız.\n\nBelirlediğiniz Başlangıç Tarihi nedeni ile girilebilecek en büyük Bitiş Tarihi="+document.arama.takvim1.value.substring(0,2)+"."+document.arama.takvim1.value.substring(3,5)+"."+(parseInt(document.arama.takvim1.value.substring(6,10),10)+1))
		return false;
	}

	//submit butonu pasifleştirecek
	document.arama.submit.disabled=true;
	return true;
}

//yeni pencere açma fonksiyonu
function yenipencere(url,ad,g,y)
{	
	var win=null;
	settings='width='+g+',height='+y+',top='+(screen.height-y)/3+',left='+(screen.width-g)/2+',scrollbars=no,location=no,directories=no,status=no,menubar=no,toolbar=no,resizable=yes';
	win=window.open(url,ad,settings);
	win.focus();
}
//yeni pencere açma fonksiyonu(kaydırma çubuklu)
function ypsc(url,ad,g,y)
{	
	var win=null;
	settings='width='+g+',height='+y+',top='+(screen.height-y)/3+',left='+(screen.width-g)/2+',scrollbars=yes,location=no,directories=no,status=no,menubar=no,toolbar=no,resizable=yes';
	win=window.open(url,ad,settings);
	win.focus();
}
//yeni pencere açma fonksiyonu(kenar mesafeli)
function ypm(url,ad,gf,yf)
{	
	var win=null;
	settings='width='+(screen.width-gf)+',height='+(screen.height-yf)+',top='+(yf/3)+',left='+(gf/2)+',scrollbars=no,location=no,directories=no,status=yes,menubar=no,toolbar=no,resizable=no';
	win=window.open(url,ad,settings);
	win.focus();
}

//kupür aç
function kac(url)
{	
	if(window.name=="ybkupur")
	eval("location='"+url+"'");
	else
	{
		g=screen.width-30;
		y=screen.height-100;
		settings='width='+g+',height='+y+',top=18,left=10,scrollbars=no,location=no,directories=no,status=yes,menubar=no,toolbar=no,resizable=yes';
		win=window.open(url,"ybkupur",settings);
		win.focus();
	}
}


function sg(selObj)//sayfaya git
{
	eval("location='?"+selObj.name+"="+selObj.options[selObj.selectedIndex].value+"'");
}

function bg(no)
{
	if(no==1)
	eval("location='yb_index.php'");
	else if(no==2)
	eval("location='gb_index.php'");
	else if(no==3)
	eval("location='rd_index.php'");
	else if(no==4)
	eval("location='eb_index.php'");
	else if(no==5)
	eval("location='ha_index.php'");
	else if(no==6)
	eval("location='koseyazarlari.php'");
	else if(no==7)
	eval("location='yayinsayfalari.php'");
	else if(no==8)
	eval("location='medyaaramamotoru.php'");
	else if(no==9)
	eval("location='ajanshaberleri.php'");
	else if(no==10)
	;//eval("location='sondakika.php?liste'");	
}

function ms(nesne)//menü seç
{
	if(nesne.selectedIndex!=0)
	{
		var win=null;
		sag=80;
		ust=140;
		ayar='width='+(screen.width-(sag*2))+',height='+(screen.height-(ust*2))+',top='+ust+',left='+sag+',scrollbars=yes,location=no,directories=no,status=no,menubar=yes,toolbar=no,resizable=yes';
		win=window.open(nesne.id+nesne.options[nesne.selectedIndex].value,nesne.name,ayar);
		nesne.selectedIndex=0;
		win.focus();
	}
}


function msb(nesne,gen,yuk)//menü seç(boyutlu)
{
	if(nesne.selectedIndex!=0)
	{
		var win=null;
		ayar='width='+gen+',height='+yuk+',top='+((screen.height-yuk)/3)+',left='+((screen.width-gen)/2)+',scrollbars=no,location=no,directories=no,status=no,toolbar=no,resizable=yes';
		win=window.open(nesne.id+nesne.options[nesne.selectedIndex].value,nesne.name,ayar);
		nesne.selectedIndex=0;
		win.focus();
	}
}



//resim büyütme ve küçülme fonksiyonları
var pm=0;
function calistirzoom(dislem)
{
	pm=dislem;
	boyutlandir();
	if(dislem!=0)
	bi=setInterval( "boyutlandir()",300);
}

function boyutlandir()
{
	if(typeof(iframe.document.res1)=='undefined')
	return;

	if(typeof(iframe.document.res1.og)=='undefined')
	{
		if(iframe.document.res1.width>30)
		iframe.document.res1.og=iframe.document.res1.width;
		else
		return;
	}

	var deger=75;
	if(pm==1)
	{
		if(iframe.document.res1.width<120)
		return;
		iframe.document.res1.width=iframe.document.res1.width-deger;
	}
	else if(pm==2)
	{
		if(iframe.document.res1.width>5000)
		return;
		iframe.document.res1.width=iframe.document.res1.width+deger;
	}
	else
	iframe.document.res1.width=iframe.document.res1.og;
}

function toplusecim()
{
	if(typeof(document.secimform.secim.id)=='undefined')
	for(var s=0; s<document.secimform.secim.length; s++)
	document.secimform.secim[s].checked=document.secimform.tumsecim.checked;
	else
	document.secimform.secim.checked=document.secimform.tumsecim.checked;
}

function pdfsecim()
{
	if(typeof(document.secimform.secim.id)=='undefined')
	for(var s=0; s<document.secimform.secim.length; s++)
	document.secimform.secim[s].checked=(document.secimform.secim[s].value=="0"?true:false);
	else
	document.secimform.secim.checked=(document.secimform.secim.value=="0"?true:false);
}

function secimisleyp(url,ad,g,y)
{
	var idst="";
	if(typeof(document.secimform.secim.id)=='undefined')
	{
		for(var s=0; s<document.secimform.secim.length; s++)
		if(document.secimform.secim[s].checked)
		idst+=(idst!=""?",":"")+document.secimform.secim[s].id;
	}
	else if(document.secimform.secim.checked)
	idst=document.secimform.secim.id;

	if(idst!="")
	yenipencere(url+"="+idst,ad,g,y);
	else
	alert("Bu özelliği kullanabilmek için listeden seçim yapmalısınız.");
}

function secimisle(nes,sor)
{
	var idst="";
	if(typeof(document.secimform.secim.id)=='undefined')
	{
		for(var s=0; s<document.secimform.secim.length; s++)
		if(document.secimform.secim[s].checked)
		idst+=(idst!=""?",":"")+document.secimform.secim[s].id;
	}
	else if(document.secimform.secim.checked)
	idst=document.secimform.secim.id;

	if(idst!="")
	nes.href=nes.id+"="+idst;
	else
	{
		alert("Bu özelliği kullanabilmek için listeden seçim yapmalısınız.");
		return false;
	}

	if(sor!="")
	return confirm(sor);

	return true;
}

function trim(st)
{
	while (st.substring(0,1)==' ')
	st=st.substring(1,st.length);
	while (st.substring(st.length-1, st.length)==' ')
	st=st.substring(0,st.length-1);
	return st;
}

function onkeyPressforesc(e)
{
var kC=(window.event)?event.keyCode:e.keyCode;
var Esc = (window.event)?27:e.DOM_VK_ESCAPE
if(kC==Esc)
window.close();
}