function ajax_getir(target_url,target_id){ 
//alert(target_url+target_id)
isleyici(target_url,target_id)

}
function yeni_nesne(){
	var nesneyarat;
	/*@cc_on @*/
	/*@if (@_jscript_version >= 5) try { nesneyarat = new ActiveXObject("Msxml2.XMLHTTP"); }
	catch (e) {
		try { nesneyarat = new ActiveXObject("Microsoft.XMLHTTP"); }
		catch (E) { nesneyarat = false; }
	}@end @*/
	if (!nesneyarat && typeof XMLHttpRequest!='undefined') {
	 try {
	  nesneyarat= new XMLHttpRequest();
	 } catch (e) {
	  nesneyarat=false;
	 }
	}
	return nesneyarat;
}

function loading(hedef,mesaj) {
		document.getElementById(hedef).innerHTML = "<table  align=left class=p width=100% cellspacing=0 cellpadding=0 height=25 ><tr><td align=left><img src=\"images/load.gif\" alt=\"Lütfen bekleyiniz...\" align=\"absmiddle\" /> &nbsp; <font-size: 14px;\"><font color=#00E2E8>"+mesaj+"</font></td></tr></table>"
	}


function isleyici(url,hedef){
loading(hedef,'Yukleniyor')
	var ajax_nesne = yeni_nesne();
	ajax_nesne.onreadystatechange = function(){ yukle(ajax_nesne,hedef) }
	ajax_nesne.open('GET', url, true)
	ajax_nesne.setRequestHeader("Content-type", "application/x-www-form-urlencoded; charset=UTF-8");
	ajax_nesne.setRequestHeader("Cache-Control", "no-cache");
	ajax_nesne.send(null)
	}

function yukle(islemci,hedef){
	if (islemci.readyState == 4 && (islemci.status==200 || window.location.href.indexOf("http")==-1)){
	document.getElementById(hedef).innerHTML="";
	document.getElementById(hedef).innerHTML = islemci.responseText
	}
		}
		
function trmove(nesne)
{
nesne.style.background="#D2EAF6"
nesne.style.cursor="hand"
}
function trout(nesne,c)
{
nesne.style.background=c
}

function sil(hedef){

ajax_getir("resimSil.asp?id="+hedef+"",hedef)
document.getElementById(hedef).innerHTML="&nbsp"
}

function pencere(url,w,h){

	x = Math.ceil( (window.screen.width  - w) / 2 )
	y = Math.ceil( (window.screen.height - h) / 2 )

	window.open(url, 'Sample', 'toolbar=no,left='+x+',top='+y+',location=no,directories=no,status=no,menubar=no,scrollbars=yes,resizable=no,copyhistory=yes,width='+w+',height='+h+'')
}
