function harfbuyut(obj){
	obj.value=obj.value.toUpperCase();
}
function harfkucult(obj){
	obj.value=obj.value.toLowerCase();
}
function disableButton(buttonID) {
                document.getElementById(buttonID).disabled=true;
   }
   
var win=null;
function NewWindow(mypage,myname,w,h,scroll,pos){
if(pos=="random"){LeftPosition=(screen.width)?Math.floor(Math.random()*(screen.width-w)):100;TopPosition=(screen.height)?Math.floor(Math.random()*((screen.height-h)-75)):100;}
if(pos=="center"){LeftPosition=(screen.width)?(screen.width-w)/2:100;TopPosition=(screen.height)?(screen.height-h)/2:100;}
else if((pos!="center" && pos!="random") || pos==null){LeftPosition=0;TopPosition=20}
settings='width='+w+',height='+h+',top='+TopPosition+',left='+LeftPosition+',scrollbars='+scroll+',location=no,directories=no,status=no,menubar=no,toolbar=no,resizable=yes';
win=window.open(mypage,myname,settings);}


function loadinparent(url, closeSelf){
	self.opener.location = url;
	if(closeSelf) self.close();
	}
function printpage() {
  window.print();  
  }
  
function favorilereekle(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 flash_goster(file,width,height){
document.writeln("<OBJECT classid='clsid:D27CDB6E-AE6D-11cf-96B8-444553540000' codebase='http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0' WIDTH='"+width+"' HEIGHT='"+height+"' id='contents' ALIGN=''>");
document.writeln("<PARAM NAME=movie value='"+file+"' />");
document.writeln("<PARAM NAME=quality VALUE=high>");
document.writeln("<PARAM NAME=bgcolor VALUE=#FFFFFF>");
document.writeln("<PARAM NAME=wmode VALUE=transparent> ");
document.writeln("<embed src='"+file+"' quality='high' bgcolor='#FFFFFF' width='"+width+"' height='"+height+"' name='contents' wmode='transparent' align='middle' allowScriptAccess='sameDomain' type='application/x-shockwave-flash' pluginspage='http://www.macromedia.com/go/getflashplayer' />");
document.writeln("</OBJECT>");
}







function no_frame()
{

  if (top.location != location) {
    top.location.href = document.location.href ;
  }
}


function kontrolet(){
var anin = document.getElementById('ctl00_Ust728_1_txt_ara').value;

if (anin==''|anin=='Hemen Ara'){

alert('Lütfen aranacak kelimeyi giriniz.');
document.getElementById('ctl00_Ust728_1_txt_ara').focus();
}

else {

window.location.href='/ara/' + anin.replace(" ", "-") + '';

}

}

function onEnter( evt, frm ) {
var keyCode = null;

if( evt.which ) {
keyCode = evt.which;
} else if( evt.keyCode ) {
keyCode = evt.keyCode;
}
if( 13 == keyCode ) {
kontrolet();
return false;
}
return true;
}



$(function () {
			var tabContainers = $('div#categories > div');
			tabContainers.hide().filter(':first').show();
			
			$('div#categories ul#catHeads li a').click(function () {
				tabContainers.hide();
				tabContainers.filter(this.hash).slideDown();
				$('ul#catHeads li a').removeClass('selected');
				$(this).addClass('selected');
				return false;
			}).filter(':first').click();
		});
		
		$(function () {
			var videoContainers = $('div#videoArea > div');
			videoContainers.hide().filter(':first').show();
			
			$('div#videoRight ul li a').click(function () {
				videoContainers.hide();
				videoContainers.filter(this.hash).show();
				$('div#videoRight ul li a').removeClass('selected');
				$(this).addClass('selected');
				return false;
			}).filter(':first').click();
		});
		
		$(function () {
			var videoContainers = $('div#commentArea > div');
			videoContainers.hide().filter(':first').show();
			
			$('ul#commentMenu li a').click(function () {
				videoContainers.hide();
				videoContainers.filter(this.hash).show();
				$('ul#commentMenu li a').removeClass('selected');
				$(this).addClass('selected');
				return false;
			}).filter(':first').click();
		});
