if (!selmenu>-1) var selmenu=0
if (!selmenu2>-1) var selmenu2=0


function initmenu() {
for (m=1; m<11; m++){
	if (m==selmenu) continue
	if (!document.getElementById('m'+m)) break
	obje=document.getElementById('m'+m)
	obje.mmm=m
	obje.onmouseover=function (){ 
				kac=this.mmm
				this.src='images/m'+kac+'_f2.png'
				this.style.cursor='pointer'
			}
	obje.onmouseout=function (){ 
				kac=this.mmm
				this.src='images/m'+kac+'.png'
			}
}

if (selmenu>0) {
	document.getElementById('m'+selmenu).src='images/m'+selmenu+'_f2.png'
}

for (m=1; m<15; m++){
	if (m==selmenu2) continue
	if (!document.getElementById('lc'+m)) break
	obje=document.getElementById('lc'+m)
	obje.mmm=m
	obje.onmouseover=function (){
				kac=this.mmm
				document.getElementById('lc'+kac).className='td2'
				this.style.cursor='pointer'
			}
	obje.onmouseout=function (){ 
				kac=this.mmm
				document.getElementById('lc'+kac).className='td1'
			}
	obje.onclick=function (){ 
				kac=this.mmm
				linkto=document.getElementById('la'+kac).href
				location.href=linkto
			}
}

if (selmenu2>0) {
	document.getElementById('lc'+selmenu2).className='td2'
}

}

function yasal() {
	var help=window.open('yasal.php', 'yasal', 'width=490,height=270,status=no,toolbar=no,scrollbars=yes,menubar=no,top=30,left=40,resizable=no,location=no');
}

function iletisim() {
	var help=window.open('iletisim.php', 'iletisim', 'width=490,height=270,status=no,toolbar=no,scrollbars=yes,menubar=no,top=30,left=40,resizable=no,location=no');
}

function contact() {
	var help=window.open('../images/kroki.html', 'kroki', 'width=760,height=433,status=no,toolbar=no,scrollbars=no,menubar=no,top=30,left=40,resizable=no,location=no');
}

function kalite(belge) {
	var help=window.open('../images/'+belge, 'belge', 'width=640,height=470,status=no,toolbar=no,scrollbars=yes,menubar=no,top=30,left=40,resizable=no,location=no');
}


function ara() {
	var keyword=document.getElementById('keyword').value,
	adres='search.php?limit=100&action=SEARCH&keyword='+keyword;
	location.href=adres;
}

function findPosY(obj)
  {
    var curtop = 0;
    if(obj.offsetParent)
        while(1)
        {
          curtop += obj.offsetTop;
          if(!obj.offsetParent)
            break;
          obj = obj.offsetParent;
        }
    else if(obj.y)
        curtop += obj.y;
    return curtop;
}

function findPosX(obj)
{
        var curleft = 0;
        if (obj.offsetParent)
        {
                while (obj.offsetParent)
                {
                        curleft += obj.offsetLeft
                        obj = obj.offsetParent;
                }
        }
        else if (obj.x)
                curleft += obj.x;
        return curleft;
}

function bulten() {window.open('bulten.html','bulten','width=500,height=180,scrollbars=no');}
