/*
<APLIMAX>
	KOÇTAŞ - Koçtaş E-Ticaret
	-- public.js --
	maximize your business
	www.aplimax.com
</APLIMAX>
*/


// -------------------------------------------------------------------
var __NS = (navigator.appName.indexOf("Netscape") != -1) || window.opera;
function iecompattest(){ // Dkman tipine gre IE test
// -------------------------------------------------------------------
	return (document.compatMode && document.compatMode!="BackCompat") ? document.documentElement : document.body
// -------------------------------------------------------------------
} // function iecompattest(){
// -------------------------------------------------------------------





// -------------------------------------------------------------------
function getScrollY(){ // Scroll Y uzakl
// -------------------------------------------------------------------
	var x = __NS ? pageYOffset : iecompattest().scrollTop;
	return(x);
// -------------------------------------------------------------------
} //function getScrollY(){
// -------------------------------------------------------------------





// -------------------------------------------------------------------
function getScrollX(){ // Scroll X uzakl
// -------------------------------------------------------------------
	var x = __NS ? pageXOffset : iecompattest().scrollLeft;
	return(x);
// -------------------------------------------------------------------
} // function getScrollX(){
// -------------------------------------------------------------------





// -------------------------------------------------------------------
function getClientW(){ // Browser ic genislik
// -------------------------------------------------------------------
	var x = __NS ? innerWidth : iecompattest().clientWidth;
	return(x)
// -------------------------------------------------------------------
} // function getClientW(){
// -------------------------------------------------------------------






// -------------------------------------------------------------------
function getClientH(){ // Browser ic yukseklik
// -------------------------------------------------------------------
	var x = __NS ? innerHeight : iecompattest().clientHeight;
	return(x);
// -------------------------------------------------------------------
} // function getClientH(){
// -------------------------------------------------------------------





// -------------------------------------------------------------------
function getElementPos(paramElement, paramDir){ // elementin sayfadaki yeri - paramDir 'x' / 'y'
// -------------------------------------------------------------------
	(paramDir=="x") ? pos = paramElement.offsetLeft : pos = paramElement.offsetTop;
	tempElement = paramElement.offsetParent;
	while(tempElement != null){
		pos += (paramDir=="x") ? tempElement.offsetLeft : tempElement.offsetTop;
		tempElement = tempElement.offsetParent;
	}
	return(pos);
// -------------------------------------------------------------------
} // function getElementPos(paramElement,paramDir){
// -------------------------------------------------------------------





// -------------------------------------------------------------------
function getMaxLength(e){
// -------------------------------------------------------------------
	var maxLength = 0;
	if(!e.getAttributeNode("maxlength")){alert('Kontrol etmek istediğiniz alanda maxlength eklenmesi gerekmektedir.\n\nÖrnek : maxlength="300"'); return(0);}
	if(typeof(e) == 'object'){maxLength = e.getAttributeNode("maxlength").value;}
	return(maxLength);
// -------------------------------------------------------------------
} //function getMaxLength(e){
// -------------------------------------------------------------------





// -------------------------------------------------------------------
function showCounter(eName){ // Check Form Text Element
// -------------------------------------------------------------------
	var e = $(eName);
	var eC = $('eCounter');
	var mL = getMaxLength(e);
	var eVL = e.value.length;
	var eX =  getElementPos(e, 'x');
	var eY =  getElementPos(e, 'y');
	var eW = e.getWidth();
	var eH = e.getHeight();
	
	eC.style.display = '';
	eC.style.top = eY + 'px';
	eC.style.left = (eX + eW) + 'px';
	eC.value = (mL - eVL);
	//e.className = 'formItemFocus';
	(e.className == 'TextArea' ? e.className = 'TextAreaFocus' : e.className = 'TextBoxFocus');

	if (e.value.length > mL){
		e.value = e.value.substring(0,mL)
		eC.value = 0;
	}

	var txt = '';
	txt += 'maxLength : ' + mL + ' \n';
	txt += 'eX : ' + eX + ' \n';
	txt += 'eY : ' + eY + ' \n';
	txt += 'eW : ' + eW + ' \n';
	txt += 'eH : ' + eH + ' \n';
// -------------------------------------------------------------------
} // function showCounter(eName){ // Check Form Text Element
// -------------------------------------------------------------------






// -------------------------------------------------------------------
function clearCounter(eName){
// -------------------------------------------------------------------
	var e = $(eName);
	var eC = $('eCounter');
	eC.style.display = 'none';
	eC.style.top = 0+ 'px';
	eC.style.left = 0 + 'px';
	eC.value = 0;
	//e.className = 'formItem';
	(e.className == 'TextAreaFocus' ? e.className = 'TextArea' : e.className = 'TextBox');
// -------------------------------------------------------------------
} // function clearCounter(eName){
// -------------------------------------------------------------------





// -------------------------------------------------------------------
fixpng = function(){
// -------------------------------------------------------------------
	
	var arVersion = navigator.appVersion.split("MSIE")
	var version = parseFloat(arVersion[1])

	if ((version >= 5.5) && (document.body.filters)){
		 for(var i=0; i<document.images.length; i++){
				var img = document.images[i]
				var imgName = img.src.toUpperCase()
				if (imgName.substring(imgName.length-3, imgName.length) == "PNG"){
					var imgID = (img.id) ? "id='" + img.id + "' " : ""
					var imgClass = (img.className) ? "class='" + img.className + "' " : ""
					var imgTitle = (img.title) ? "title='" + img.title + "' " : "title='" + img.alt + "' "
					var imgStyle = "display:inline-block;" + img.style.cssText 
					if (img.align == "left") imgStyle = "float:left;" + imgStyle
					if (img.align == "right") imgStyle = "float:right;" + imgStyle
					if (img.parentElement.href) imgStyle = "cursor:hand;" + imgStyle
					var strNewHTML = "<span " + imgID + imgClass + imgTitle
					+ " style=\"" + "width:" + img.width + "px; height:" + img.height + "px;" + imgStyle + ";"
					+ "filter:progid:DXImageTransform.Microsoft.AlphaImageLoader"
					+ "(src=\'" + img.src + "\', sizingMethod='scale');\"><img src=\"/images/s.gif\" width="+img.width+" height="+img.height+"></span>" 
					img.outerHTML = strNewHTML
					i = i-1
				}
		 }
	}
// -------------------------------------------------------------------
} //fixpng = function(){
// -------------------------------------------------------------------





// -------------------------------------------------------------------
function rakamKontrol(paramTarget){
// -------------------------------------------------------------------
    t = $(paramTarget);
    v = $F(paramTarget);
    if(isNaN(parseInt(v))){
        t.value = 0;
        t.select();
    }else{
        t.value = parseInt(v);
    }
// -------------------------------------------------------------------
} // function rakamKontrol(paramTarget){
// -------------------------------------------------------------------





// -------------------------------------------------------------------
function FIXjumpMenu(targ,selObj,restore){ //v3.0
// -------------------------------------------------------------------
  eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'");
  if (restore) selObj.selectedIndex=0;
// -------------------------------------------------------------------
} //function MM_jumpMenu(targ,selObj,restore){ //v3.0
// -------------------------------------------------------------------





// -------------------------------------------------------------------
function showHideDiv(paramTargetDiv){
// -------------------------------------------------------------------
	var td = $(paramTargetDiv);
	if(td.style.display.length< 4){
		td.style.display = "none";
	}else{
		td.style.display = "";
	}
// -------------------------------------------------------------------
} // function showHideDiv(paramTargetDiv){
// -------------------------------------------------------------------





// -------------------------------------------------------------------
function showDiv(paramTargetDiv){
// -------------------------------------------------------------------
	var td = $(paramTargetDiv);
	td.style.display = "";
// -------------------------------------------------------------------
} // function showDiv(paramTargetDiv){
// -------------------------------------------------------------------





// -------------------------------------------------------------------
var formIlkDeger = '';
var formItemDegisim = false;
function focusFormItem(paramItem, paramIlkDeger){
// -------------------------------------------------------------------
	if(formItemDegisim == false){
		formIlkDeger = paramIlkDeger;
		paramItem.value = '';
	}
// -------------------------------------------------------------------
} // function focusFormItem(paramItem){
// -------------------------------------------------------------------


// -------------------------------------------------------------------
function blurFormItem(paramItem){
// -------------------------------------------------------------------
		if(formIlkDeger != paramItem.value){
				if(paramItem.value.length < 1){
					formItemDegisim = false;
					paramItem.value = formIlkDeger;
				}else{
					formItemDegisim = true;
				}
		}else if(paramItem.length < 1){
				formItemDegisim = false;		
				paramItem.value = formIlkDeger;
		}else{
				formItemDegisim = false;		
				paramItem.value = formIlkDeger;
		}		
// -------------------------------------------------------------------
} // function blurFormItem(paramItem){
// -------------------------------------------------------------------





function checkemail(paramEmail){
	var filter = /^([\w-]+(?:\.[\w-]+)*)@((?:[\w-]+\.)*\w[\w-]{0,66})\.([a-z]{2,6}(?:\.[a-z]{2})?)$/i;
	(filter.test(paramEmail) ? testresults = true : testresults = false); return(testresults);
}




// -------------------------------------------------------------------
function divAyarla(){ // Sağ Sol Orta boyutlarına göre sayfa altını ayarlar
// -------------------------------------------------------------------
	var SM = $('SM');
	var SMFake = $('SiteMiddleFake');
	var SMH = SM.getHeight();

	
	var SiteRight = $('SiteRight');
	var SiteLeft = $('SiteLeft');
    var SRH =  SiteRight.getHeight();
    var SLH = SiteLeft.getHeight();

	//SMFake.style.height = SMH + 20 + 'px';

  var MaxHeight = 0;
  var Values = new Array();
  Values[0] = SLH;
  Values[1] = SRH;
  Values[2] = SMH;
  
  
  for (i=0; i<3; i++) {
    if (Values[i] > MaxHeight) {
      MaxHeight = Values[i];
    }
  }

	if( MaxHeight > 390 ){
	    SMFake.style.height = MaxHeight -2 + 'px';
	    SiteRight.style.height = MaxHeight -2 + 'px';
	    SiteLeft.style.height = MaxHeight -2 + 'px';
	}else{
		SMFake.style.height = 392  + 'px';
	    SiteRight.style.height = 392 + 'px';
	    SiteLeft.style.height = 392 + 'px';
	}
// -------------------------------------------------------------------
} //function divAyarla(){
// -------------------------------------------------------------------


// -------------------------------------------------------------------
// FLYER - BASLA -----------------------------------------------------
var hideID = 0;
var EffectInProgress = 0;
var flyer = function(paramDivID, paramWidth, paramHeight, paramIcerik, paramBaslik, paramResimPath, paramLink, paramTema){
// -------------------------------------------------------------------
	//flyerTuruncu, flyerBeyaz, flyerGri
	var Tema = '';
	var sHTML = '';
	
	clearAdInterval();
	
	(paramHeight == undefined ? paramHeight = 'auto' : '');
	(paramWidth == undefined ? paramWidth = '200' : '');
	(paramIcerik == undefined ? paramIcerik = '' : '');
	(paramBaslik == undefined ? paramBaslik = '' : '');
	(paramResimPath == undefined ? paramResimPath = '' : '');
	(paramLink == undefined ? paramLink = '' : '');
	(paramTema == undefined ? paramTema = 'beyaz' : '');

	if(paramTema == 'beyaz'){
		Tema = 'flyerBeyaz';
	}else if(paramTema == 'turuncu'){
		Tema = 'flyerTuruncu';
	}else if(paramTema == 'gri'){
		Tema = 'flyerGri';
	}else{
		Tema = 'flyerBeyaz';
	}

	var flyer = $('FIXFlyer');
	var closer = $('FIXCloser');
	var dummy = $('FIXDummy');
	flyer.style.display = 'none';
	var tempDiv = $(paramDivID);
	var tempDivX = getElementPos(tempDiv, 'x');
	var tempDivY = getElementPos(tempDiv, 'y');
	var tempDivW = tempDiv.getWidth();
	var tempDivH = tempDiv.getHeight();
	
	var flyerX = tempDivX;
	var flyerY = tempDivY ;//+ tempDivH + 2;

	var txt = '';
	txt = 'tempDivX : ' + tempDivX + '\n'
	txt += 'tempDivY : ' + tempDivY + '\n'
	txt += 'tempDivW : ' + tempDivW + '\n'
	txt += 'tempDivH : ' + tempDivH + '\n'
	
	
	sHTML = "";
	
	sHTML = '<div href="javascript:;" onmousemove="javascript://clearAdInterval();" onmouseout="javascript:hideAd();">'
//	if(paramBaslik.length > 5){
//		if(paramLink.length > 5){
//			sHTML += '<div class="flyerBaslik"><b><a href="' + paramLink + '">' + paramBaslik + '</a></b></div>';
//		}else{
//			sHTML += '<div class="flyerBaslik"><b>' + paramBaslik + '</b></div>';
//		}
//	}
	
	sHTML += '<div class="cleaner"><img src="/images/s.gif" width="1" height="1" border="0" /></div>';
	
	if(paramResimPath.length > 5){
	sHTML = '<img alt="" src="'+paramResimPath+'" onerror=\'javascript:$("flyerResim").style.background=\"url(/imagearea/products/small/noimage.jpg) no-repeat scroll center\";\' style=\"display: none;\" />';
		if(paramLink.length > 5){
			sHTML += '<div class="flyerIcerik" style="float:left;"><a href="' + paramLink + '"><img id="flyerResim" width="62" height="72" src="/images/s.gif" alt="'+paramBaslik+'" style="border: 0px none; background: url('+paramResimPath+') no-repeat center 50%;" /></a></div><div class="flyerIcerik" style="float:left; width:92px; margin-left:2px;"><a href="' + paramLink + '">' + paramBaslik + '</a></div>';			
		} else {
			sHTML += '<div class="flyerIcerik"><img id="flyerResim" width="62" height="72" src="images/s.gif" alt="'+paramBaslik+'" style="border: 0px none; background: url('+paramResimPath+') no-repeat center 50%;" />' + paramBaslik + '</div>';			
		}
	} else {
		if(paramLink.length > 5){
			sHTML += '<div class="flyerIcerik" style="float:left;"><a href="' + paramLink + '">' + paramBaslik + '</a></div>';
		}else{
			sHTML += '<div class="flyerIcerik" style="float:left;">' + paramBaslik + '</div>';
		}
	}





	sHTML += '<div class="cleaner"><img src="/images/s.gif" width="1" height="1" border="0" /></div>';
	sHTML += '<div class="flyerAciklama" style="float:left"><a class="flyerAciklama" href="' + paramLink + '">' + paramIcerik + '</a></div>';			
	sHTML += '</div>';

	flyer.className = Tema;
	//flyer.style.margin = flyerY + 'px 0px 0px ' + flyerX + 'px';
	flyer.style.width = paramWidth + 'px';
	flyer.style.height = paramHeight + 'px';
	dummy.style.width = '164' + 'px';
	dummy.style.height = '237' + 'px';
	//flyer.style.height = 'auto';//paramHeight + 'px';
	//flyer.style.width = tempDivW;
	//flyer.style.height = tempDivH;
    
    dummy.innerHTML = '<a href="' + paramLink + '"><img src="images/s.gif" width="164" height="210" alt="" border="0"/><br /><img src="images/s.gif" width="118" height="27" alt="" border="0"/></a>'; 
    dummy.style.display = 'block';
	flyer.style.display = 'block';
	if(EffectInProgress == 1){
	EffectInProgress=2;
	new Effect.BlindUp($('FIXFlyer'), {afterFinish: function(){	EffectInProgress=2; flyer.innerHTML = sHTML; dummy.style.margin = flyerY + 'px 0px 0px ' + flyerX + 'px'; flyer.style.margin = flyerY + 'px 0px 0px ' + flyerX + 'px'; new Effect.BlindDown($('FIXFlyer'), {afterFinish: function(){EffectInProgress = 1;}})}});
	}else {
	    if(EffectInProgress== 0){
	        EffectInProgress = 2;
	        flyer.innerHTML = sHTML;
	        flyer.style.margin = flyerY + 'px 0px 0px ' + flyerX + 'px';
	        dummy.style.margin = flyerY + 'px 0px 0px ' + flyerX + 'px';
	        new Effect.BlindDown($('FIXFlyer'),{afterFinish: function(){EffectInProgress = 1;}});
	    }
	}
	
// -------------------------------------------------------------------
} // var flyer = function(paramDiv, paramWidth, paramHeight, paramBaslik, paramIcerik, paramResimPath, paramTema){
	
function clearFlyer(){
	clearInterval(hideID);
	var flyer = $('FIXFlyer');
	var closer = $('FIXCloser');
//	flyer.style.margin = '0px 0px 0px 0px';
//	flyer.innerHTML = ''
//	flyer.className = '';
//	flyer.style.display = 'none';
}

function clearAdInterval(){
	clearInterval(hideID);
}

function hideAd(){
		clearInterval(hideID);
		hideID = setInterval(clearFlyer, 50);
}
// FLYER - BITTI -----------------------------------------------------
// -------------------------------------------------------------------

// Urun Box Tamamlayici - BASLA --------------------------------------
function boxTamamlayici(){
//	try{
//		var Urun_1 = document.getElementsByClassName("Urun_1");
//		var boxSayi = parseInt(Urun_1.length);
//		var	BosBoxHtml = '';
//		var cleanerHtml = '';
//		var basilacakHTML = '';
//	
//		BosBoxHtml = '<span>';
//		BosBoxHtml += '<div class="Urun_1">';
//		BosBoxHtml += '  <div class="UrunIc_1">';
//		BosBoxHtml += '    <div class="Resim_1"><img src="images/s.gif" width="155" height="170" border="0" alt="" /></div>';
//		BosBoxHtml += '    <div class="UrunAdi_1">&nbsp;</div>';
//		BosBoxHtml += '    <div class="Fiyat_1">&nbsp;</div>';
//		BosBoxHtml += '    <div class="Info_1"><img src="images/s.gif" width="19" height="19" />&nbsp;&nbsp;<img src="images/s.gif" width="19" height="19" /></div>';
//		BosBoxHtml += '    <div class="cleaner"><img src="/images/s.gif" width="1" height="1" /></div>';
//		BosBoxHtml += '  </div>';
//		BosBoxHtml += '</div>';
//		BosBoxHtml += '</span>';
//		
//		cleanerHtml = '<div class="cleanYatayNokta"><img src="/images/s.gif" width="1" height="1" /></div>';
//		
//		for(var i=0; i<Urun_1.length; i++){Urun_1[i].id = "sayfaUrunBox" + i;}

//		switch(boxSayi%3){
//			case 0:
//				break;
//			case 1:
//				basilacakHTML = BosBoxHtml + BosBoxHtml + cleanerHtml;
//				new Insertion.After('sayfaUrunBox' + (boxSayi-1), basilacakHTML);
//				break;
//			case 2:	
//			    basilacakHTML = BosBoxHtml + cleanerHtml;
//				new Insertion.After('sayfaUrunBox' + (boxSayi-1), basilacakHTML); 
//				break;
//			default:
//				break;
//		}

//	}catch(e){
//		//alert(e.description);
//	}
}
// Urun Box Tamamlayici - BİTİR --------------------------------------

function begendiklerimKontrol(){ 
alert('Beğendiğiniz ürünleri düzenlemek için üye girişi yapmalısınız.'); 
return false;
}


function isNumeric(value) {
  if (value == null || !value.toString().match(/^[-]?\d*\.?\d*$/)) return false;
  return true;
}



function cv2Kontrol(sender, args)
    {
      var cv2 = args.Value ;
      
      if(isNumeric(cv2) && cv2.length ==3){
     args.IsValid = true;
     }else{ 
      args.IsValid = false;
     } 
     
    }
   
  function krediKartKontrol(sender, args)
    {
      var krediKart = args.Value ;
      
     //LUHN algorithm 
      if(isNumeric(krediKart) && krediKart.length ==16){
     args.IsValid = true;
     }else{ 
      args.IsValid = false;
     } 
     
    }  
   
    function sehirKontrol(sender, args)
    {
      var sehir = args.Value ;
      
      if(isNumeric(sehir) ){
     args.IsValid = true;
     }else{ 
      args.IsValid = false;
     } 
     
    }  
   
      function ePostaKontrol(sender, args)
    {
            var Email = args.Value;
            if(!checkemail(Email)){
            alert('Geçerli bir e-posta adresi giriniz');
            args.IsValid = false;
            }else{
            args.IsValid = true;
            }

     
    }   
   
  
    function cepTelefonKontrol(sender, args)
    {
      var cepTelefonu = args.Value ;
      
      if(!isNumeric(cepTelefonu) || cepTelefonu.toString().length < 10){
            args.IsValid = false;
            }else{
            args.IsValid = true;
     } 
     
    }  
    
          function postaKoduKontrol(sender, args)
    {
            var postaKodu = args.Value;
            if(!isNumeric(postaKodu) || postaKodu.length != 5){
            args.IsValid = false;
            }else{
            args.IsValid = true;
            }

     
    }   
// -------------------------------------------------------------------
// Koçtaş Alerter - BAŞLA --------------------------------------------
var alertLayout;
var alertText;
var alertImg;
var fixDiv;
var alertTimeout;

var alertShow = 0;

function koctasAlertV1(paramText){
	var main = $('main');
	fixDiv = $('FIXFlyer');
	var closer = $('FIXCloser');
	var txt = '<div id="koctasAlertLayout" style="top:0px; left:0px; position:absolute; z-index:5999;">';
	txt += '<div id="koctasAlertText" style="position:absolute; z-index:6000; font-family:Arial, Helvetica, sans-serif; font-weight:bold; font-size:11px; margin:20px 2px 2px 40px; color:#FFFFFF; width:255px; text-align:center;">' + paramText + '</div>';
	txt += '<img src="/images/koctas_alert.gif" id="koctasAlertImage" width="300" height="40" style="filter:Alpha(Opacity=0);-moz-opacity:0.0;opacity:0.0;" />';
	txt += '</div>';
	
	fixDiv.innerHTML = txt;
	fixDiv.style.display = '';
	
	var mainW  = main.getWidth();
	var mainH = main.getHeight();
	var mainX = getElementPos(main, 'x');
	var mainY = getElementPos(main, 'y');
	
	var scrY = getScrollY();
	var scrX = getScrollX();
	var clientH = getClientH();
	var clientW = getClientW();
	
	var alerterW = 300;
	var alerterH = 40;
	
	
	alertLayout = $('koctasAlertLayout');
	alertText = $('koctasAlertText');
	alertImg = $('koctasAlertImage');

	alertLayout.style.width = alerterW + "px";
	alertLayout.style.height = alerterH + "px";
	alertLayout.style.top = parseInt(((clientH / 2) + scrY) - (alerterH / 2)) + "px";
	alertLayout.style.left = parseInt(mainX + ((mainW / 2) - (alerterW / 2))) + "px";

	alertLayout.style.display = '';
	alertShow = 0;
	koctasAlertShow();
}

function koctasAlertShow(){
	try {
		alertLayout = $('koctasAlertLayout');
		alertText = $('koctasAlertText');
		alertImg = $('koctasAlertImage');
		if(alertShow != 100){
			alertShow = alertShow + 20;
			alertImg.style.filter = 'Alpha(Opacity=' + alertShow + ')';
			alertImg.style.opacity = alertShow / 100;
			//alertImg.style.opacity = '0.0';
			window.setTimeout('koctasAlertShow()',20);
		}else{
			window.setTimeout('koctasAlertHide()',5000);
			window.clearTimeout();
		}
	}catch(e){
		window.clearTimeout();
		fixDiv = $('FIXFlyer');
		fixDiv.innerHTML = '';
		fixDiv.style.margin = '0px 0px 0px 0px';
		fixDiv.innerHTML = ''
		fixDiv.className = '';
		fixDiv.style.display = 'none';
		alertShow = 0;
	}
}


function koctasAlertHide(){
	try{
		alertLayout = $('koctasAlertLayout');
		alertText = $('koctasAlertText');
		alertImg = $('koctasAlertImage');
		if(alertShow != 0){
			alertShow = alertShow - 10;
			alertImg.style.filter = 'Alpha(Opacity=' + alertShow + ')';
			alertImg.style.opacity = alertShow / 100;
			window.setTimeout('koctasAlertHide()',50);
		}else{
			fixDiv = $('FIXFlyer');
			fixDiv.innerHTML = '';
			fixDiv.style.margin = '0px 0px 0px 0px';
			fixDiv.innerHTML = ''
			fixDiv.className = '';
			fixDiv.style.display = 'none';
			window.clearTimeout();
		}
	}catch(e){
		fixDiv = $('FIXFlyer');
		fixDiv.innerHTML = '';
		fixDiv.style.margin = '0px 0px 0px 0px';
		fixDiv.innerHTML = ''
		fixDiv.className = '';
		fixDiv.style.display = 'none';
		alertShow = 0;
		window.clearTimeout();
	}
}
// Koçtaş Alerter - BITTI --------------------------------------------
// -------------------------------------------------------------------

function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}

function detayliArama(){
var msg= '';

    if($('ctl00_cphKoctasUrunNavigation_tbDetayliArama').value.length < 3){
    msg += '-En az 3 karakterlik bir anahtar kelime giriniz\n';
    }
    
    if($('ctl00_cphKoctasUrunNavigation_tbAltLimit').value.length > 0 && !isNumeric($('ctl00_cphKoctasUrunNavigation_tbAltLimit').value)){
    msg += '-Alt Limit değeri sadece sayı içerebilir\n';
    }
    
    if($('ctl00_cphKoctasUrunNavigation_tbUstLimit').value.length > 0 && !isNumeric($('ctl00_cphKoctasUrunNavigation_tbUstLimit').value)){
    msg += '-Üst Limit değeri sadece sayı içerebilir\n';
    }

    if(msg.length > 3){
    msg = 'Lütfen aşağıdaki maddeleri kontrol edin:\n\n' + msg +' ';
    alert(msg);
    return false;
    }else{
    return true;
    }
}

function threeDHost(postSayfasi){
    document.aspnetForm.action = postSayfasi;
    document.aspnetForm.submit();
}

function GroupDelegate(id) {
   var objLink = document.getElementById(id);
   Lightbox.prototype.start(objLink);
}