$(function () {
    $('.bannerCarousel').owlCarousel({
        loop:true,
        margin:0,
        nav:false,
        items: 1,
        center: true,
        dots: true,
        autoplay: true
    });

    $('.bannerReferencje').owlCarousel({
        loop:true,
        margin:0,
        nav:true,
        items: 1,
        center: true,
        dots: false,
        autoplay: true,
        navText : ['<img src="/templates/Front/habitat/assets/img/strzalka-referencje.png">','<img src="/templates/Front/habitat/assets/img/strzalka-referencje.png">']
    })
});

$("#form_1").bind("submit",function(e) {
    e.preventDefault();

    return false;
});
$("#form_1").bind("forminvalid.zf.abide", function(e,target) {

});
$("#form_1").bind("formvalid.zf.abide", function(e,target) {

    var param = $("#form_1").serialize();
    $.ajax({
        type:"POST",
        url: '/kontakt/odbierz?json=1',
        data:param,
        success: function() {
            $('.callout ').show();
            $('.contact_form').hide();
        }
    });
});
