<!--
// JavaScript Document

function WinOpen(ref,pics,title)
{
	var X = screen.width
	var Y = screen.height
	var style = "HEIGHT=100,WIDTH=100, left=" + (X-700)/2 + ",top=0,screenX=" + (X-700)/2 +",screenY=0,toolbar=no,location=no, directories=no, status=no, menubar=no, scrollbars=no, resizable=no"
	var url = 'show_image.php\?ref=' + ref + '&pics=' + pics + '&t=' + title
	window.open(url,'sub',style)
}
function windowResize(thumbs,rows)
{
	if(thumbs)
	{
		var myInnerHeight = 210;
		if(rows == 3) var myInnerHeight = 314;
		
		var myInnerWidth = 449
		window.resizeTo(myInnerWidth + 50,myInnerHeight + 100)
		
		var myW = 0, myH = 0, x = window, d = x.document.documentElement, b = x.document.body;
		if( x.innerWidth ) { myW = x.innerWidth; myH = x.innerHeight; }
		else if( d && d.clientWidth ) { myW = d.clientWidth; myH = d.clientHeight; }
		else if( b && b.clientWidth ) { myW = b.clientWidth; myH = b.clientHeight; }
	
	
		var myOuterHeight = (myInnerHeight + 100) - myH + myInnerHeight;
		var myOuterWidth = (myInnerWidth + 50) - myW + myInnerWidth;
		window.resizeTo(myOuterWidth,myOuterHeight);	
	}
	else
	{
		var myInnerHeight = window.document.getElementById('image').height + 13
		window.resizeTo(document.getElementById('image').width,myInnerHeight + 100);
		
		var myW = 0, myH = 0, x = window, d = x.document.documentElement, b = x.document.body;
		if( x.innerWidth ) { myW = x.innerWidth; myH = x.innerHeight; }
		else if( d && d.clientWidth ) { myW = d.clientWidth; myH = d.clientHeight; }
		else if( b && b.clientWidth ) { myW = b.clientWidth; myH = b.clientHeight; }
	
	
		var myOuterHeight = (myInnerHeight + 100) - myH + myInnerHeight;
		var myOuterWidth = document.getElementById('image').width;
		window.resizeTo(myOuterWidth,myOuterHeight);
	}
	
}

var oldName;
function highlight(what)
{
	if(what.selected)
	{
		what.className = oldName;
		what.selected = false;
	}
	else
	{
		oldName = what.className;
		what.className = 'high';
		what.selected = true;
	}
}

function show(id)
{
	window.location.href = 'admin_detail.php?id=' + id
}

function deleteThis(id)
{
	var x = confirm('Bu kaydı silmek istediğinizden emin misiniz?');
	
	if(x)
	{
		window.location.href = 'admin_show.php?action=delete&id=' + id
	}
	else
	{
		return false;
	}
}

//-->