New Landing How can we help? Cardinal Swiflt slider video mute

Viewing 5 posts - 16 through 20 (of 20 total)
  • Posted in: Cardinal
  • #124500
    Swift Ideas – Ed
    Keymaster
    Post count: 15264

    My mistake, please try this code (missed the document.ready wrapper)..

    jQuery(document).ready(function() {
    jQuery('.fw-video-link').on('click', function() {
            var slideVideo = jQuery( '#swift-slider-1' ).find('.swiper-slide-active video');
            if (slideVideo.length() > 0) {
                    slideVideo.get( 0 ).pause();
                    if ( slideVideo.get( 0 ).currentTime !== 0 ) {
                        slideVideo.get( 0 ).currentTime = 0;
                    }        
            }
    });
    
    jQuery('.fw-video-close').on('click', function() {
            var slideVideo = jQuery( '#swift-slider-1' ).find('.swiper-slide-active video');
            if (slideVideo.length() > 0) {
                    slideVideo.get( 0 ).play();   
            } 
    });
    });

    – Ed

    #124518
    Kirsten
    Member
    Post count: 234

    Unfortunately not

    #124524
    Rui Guerreiro – SUPPORT
    Keymaster
    Post count: 25779

    Made I slight change using length instead of length() .
    Can you test again?

    -Rui

    #124535
    Kirsten
    Member
    Post count: 234

    That worked like a charm thank you!

    #124551
    Rui Guerreiro – SUPPORT
    Keymaster
    Post count: 25779

    Great. Thanks Ed.
    -Rui

Viewing 5 posts - 16 through 20 (of 20 total)

You must be logged in and have valid license to reply to this topic.

License required for one of the following items
Login and Registration Log in · Register