// JavaScript Document
$(document).ready(function(){
/*        DISABLED RIGHT CLICK, COPY AND SELECT ALL       */
    $(this).bind("contextmenu selectstart", function(e) {
       e.preventDefault();
    });

    $(this).keydown(function(e){
        if(e.ctrlKey) { 
         var sel ;
        if(document.selection && document.selection.empty)
            {document.selection.empty() ;}
        else if(window.getSelection) {
            sel=window.getSelection();
            if(sel && sel.removeAllRanges)
            sel.removeAllRanges() ;
        }
        e.preventDefault();
        }
    });


 //$('.destination-button').corner();
  $('.dest-btn').click(function() {
      var link_id = $(this).attr('id');
      $('.dest-btn').removeClass('active-btn');
      $('#' + link_id).addClass('active-btn');

    $.post(
    'flights-list.php',
    {"loc_id" : link_id},
    function(data) {
     $('#flights-list').html(data);
    });
  });


      $.post(
    'flights-list.php',
    {"loc_id" : 1},
    function(data) {
     $('#flights-list').html(data);
     $('#1').addClass('active-btn');
    });
  
});

function FindText()
{
   var val = $('#find-text').val();
   if(val.length < 1) return false;
   $('.highlight').parent('a').css('background', '');
   $('.content-category-wrap, .private-beach-list li')
   .removeHighlight()
   .highlight(val);
   $('.highlight').parent('a').css('background', '#d0d0d0');
   $(document).scrollTop($('.highlight').position().top - 200);
}

