$(function () {
	$('.lightbox a').lightBox({
		fixedNavigation:true,
		imageLoading: '/includes/js/jquery/lightbox/lightbox-ico-loading.gif',
		imageBtnClose: '/includes/js/jquery/lightbox/lightbox-btn-close.gif',
		imageBtnPrev: '/includes/js/jquery/lightbox/lightbox-btn-prev.gif',
		imageBtnNext: '/includes/js/jquery/lightbox/lightbox-btn-next.gif',
		imageBlank: '/includes/js/jquery/lightbox/lightbox-blank.gif',
		txtOf: ' / ',
		txtImage: ''
	});
});



function update_address(id_street, id_number)
{
	$("#"+id_number).html("");
	data = 	{
		action: "search_street",
		street_id: $("#"+id_street).val()
	};
	$.post("/cp/maps.php", data, function(res){
		$("#"+id_number).html(res);
	});
}

/* BUSINESS DESCRIPTION
------------------------------------------------------------------ */
/*var More_description = {
  init: function() {
    this.setDescription();
  },
  
  setDescription: function() {
    show_height = 99;
    speed = 200;
    desc = jQuery('#group_descr');
    
    if (desc.height() > show_height+50) {
      desc.orig_height = desc.height();
      desc.css({'overflow': 'hidden', 'height': show_height+'px'});
      desc.after('<p class="more_description"><a href="#">Развернуть</a></p>');

      jQuery('.more_description a').bind('click', function(e) {
        e.preventDefault();
        if (desc.orig_height > desc.height()) {
          desc.animate({'height': desc.orig_height+'px'}, speed);
          jQuery(this).html('Свернуть');
        }
        else {
          desc.animate({'height': show_height+'px'}, speed);
          jQuery(this).html('Развернуть');
        }
      });
    }
  }
};

/* INIT
------------------------------------------------------------------ */
/*jQuery(function() {
  More_description.init();
});*/
