$(function(){
   
   $.mask.definitions['~']='[+-]';
    
    $('#iletisim_wrp .phone').focus(function () {
         $(this).mask('(999) 999-99-99',{placeholder:" "});
     });
     
    $('#iletisim_wrp .text').focus(function () {
         $(this).attr('value','');
     });
     
   $(".slidetabs").tabs(".images > div", {

	// enable "cross-fading" effect
	effect: 'fade',
	fadeOutSpeed: "slow",
        
	// start from the beginning after the last tab
	rotate: true

    // use the slideshow plugin. It accepts its own configuration
    }).slideshow(
    {
        autoplay: true,
        interval : 4000
    });
 
   
   $("a[rel^='prettyPhoto']").prettyPhoto({
	custom_markup: '<div id="map_canvas" style="width:350px; height:300px"></div>',
        autoplay_slideshow: false,
        overlay_gallery: false               
});
    
     
     $('.search_btn').click(function(){

      var langId=$('#lang_id').val();

      if($('.searchinput').val()==""){
         if(langId=='tr'){
         alert('Arama için veri giriniz!');
         return false;
         }
         else
         {alert('Please enter the search data! ');
         return false;
         }
      }else{
         return true;
      }
   });
   
     $('.search_btn').click(function(){

      var n = $('.searchinput').val().length;
      
         if(n < 3){
           alert('Çok kısa bilgi - Too short information !');
         return false;
         }
         else if( n > 100){
           alert(' Çok uzun bilgi - Too much information ! ');         
         return false;
         }
         else{
         return true;
      }
   });
  

      $('#scroller_container a').each(function()
   {
      if($(this).attr('href').length > 0)
         $(this).css('cursor','pointer');
   });
   
   
   $('.ssContent').parent('li').css('border-bottom','none');
    
   
                        
});


