• Hello,
    I’m using ele custom skin to display custom post type and facewp to add filters, but when i use the filters my image carousel stops working.

    The page I need help with: [log in to see the link]

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author dudaster

    (@dudaster)

    Thread Starter elenidicha97

    (@elenidicha97)

    I didn’t understand. Should I add this code to my site? If yes, where should I place it.?

    jQuery(document).ready(function($){
        $.ajaxSetup({cache:false});
        $(document).on('click', ".post-link", function () {
            $( ".sidebar" ).toggleClass( "sidebar-slide" );
            $( ".content-wrap" ).toggleClass( "content-slide" );
            var post_link = $(this).attr("href")+' #content';
            $("#single-post-container").html("<div class='loader'></div><span class='tload'>???????? ...</span>");
            $("#single-post-container").load($(this).attr("href")+' #content', function(response, status, xhr) { // complete callback
    
                    // create a empty div
                    var div = document.createElement('div');
                    // fill div with response
                    div.innerHTML = response;
                    // take correct part of the response
                    var ref = $($(div).find('#content').html());
                    // filter response for script tags
                    ref.filter('script').each(function () {
                        // execute the scripts
                        $.globalEval(this.text || this.textContent || this.innerHTML || '');
                    });
                    var mySwiper = $('.swiper-container').swiper({
                      mode: 'horizontal',
                      loop: true
                    })
    
            });
    
        return false;
        });
    });
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Image carousel stops working’ is closed to new replies.