function openWindow (url,w,h)
{
ow = window.open(url, "Özet", "scrollbars=yes,status=no,width="+w+",height="+h+",location=no,resizable=no");
ow.focus();
}

function openNews (url)
{
ow = window.open(url, "Özet", "scrollbars=yes,status=no,width=800,height=600,location=no,resizable=yes");
ow.focus();
}

function  ask(){
  if(typeof(inMaintenance)!='undefined' && inMaintenance == "true"){
  	alert(maintenanceText);
  	return false;
  }	
  var answer = confirm("Silme İşlemi yapmak Üzeresiniz !  Emin misiniz ? ")
     if (answer){
          return true;
      }
     else{
		return false;
     }
  
}
function toggleLayer(whichLayer) {
	if (document.getElementById) {
		// this is the way the standards work
		var style2 = document.getElementById(whichLayer).style;
		style2.display = style2.display? "":"block";
	}
	else if (document.all) {
		// this is the way old msie versions work
		var style2 = document.all[whichLayer].style;
		style2.display = style2.display? "":"block";
	}
	else if (document.layers) {
		// this is the way nn4 works
		var style2 = document.layers[whichLayer].style;
		style2.display = style2.display? "":"block";
	}
}

function bookmarksite(title,url){
if (window.sidebar) // firefox
	window.sidebar.addPanel(title, url, "");
else if(window.opera && window.print){ // opera
	var elem = document.createElement('a');
	elem.setAttribute('href',url);
	elem.setAttribute('title',title);
	elem.setAttribute('rel','sidebar');
	elem.click();
} 
else if(document.all)// ie
	window.external.AddFavorite(url, title);
}

function sethomepage(){
alert();
this.style.behavior='url(#default#homepage)';
this.setHomePage('http://www.uzerine.com');
}

function checkEmail(value , field) {
if (/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,3})+$/.test(value)){
return (true)
}
alert("Lütfen Geçerli Bir E-Posta Adresi Girin !")
field.focus();
return (false)
}
function createCookie(name,value,days) {
	if (days) {
		var date = new Date();
		date.setTime(date.getTime()+(days*24*60*60*1000));
		var expires = "; expires="+date.toGMTString();
	}
	else var expires = "";
	document.cookie = name+"="+value+expires+"; path=/";
}

function readCookie(name) {
	var nameEQ = name + "=";
	var ca = document.cookie.split(';');
	for(var i=0;i < ca.length;i++) {
		var c = ca[i];
		while (c.charAt(0)==' ') c = c.substring(1,c.length);
		if (c.indexOf(nameEQ) == 0) return c.substring(nameEQ.length,c.length);
	}
	return null;
}

function eraseCookie(name) {
	createCookie(name,"",-1);
}

