Support » Plugin: Load More Products for WooCommerce » WooCommerce Load More Products and On Mouseover

  • Resolved agunia

    (@agunia)


    Hello,
    I have your plugin (WooCommerce Load More Products) and I have plugin (Play The Video (Map,image) On Mouseover For WooCommerce). When I have infinity scroll and I mouse over the product, video doesn’t display.
    You can help me? Is the problem on the side of that plugin(Play The Video (Map,image) On Mouseover For WooCommerce)?

    Regards,
    agunia

Viewing 8 replies - 1 through 8 (of 8 total)
  • Plugin Author Dima Holovnia

    (@dholovnia)

    Hello Agunia,

    Most likely that plugin is adding JavaScript events to the video on page load. It is not the best way of doing this so it is not working.

    Please provide your site url and I’ll help you configure it to re-run their code when new products are loaded.

    Regards,
    Dima

    Hello Dima,
    Thank you for your replies.
    This is my website: https://anisment.video/kategoria-produktu/logo/
    URL to example page. After mouseover on the product from row 4 down preview video doesn’t work.
    Plugin on preview: Play The Video (Map,image) On Mouseover For WooCommerce
    Your thesis is probably the reason.
    I am waiting for a response
    Regards,
    agunia

    Hello,
    Should I continue to wait?
    Just asking because I do not receive any messages.
    If the work is in progress, I apologize and thank you
    Regards,
    Agunia

    Plugin Author Dima Holovnia

    (@dholovnia)

    Hello Agunia,

    Please open our plugin settings page and add this code to the After Update field

    
    (function($){
        var video_intro = {
            init: function(){
                $(".video_intro_product").hover(this.over, this.out);
            },
            over: function (e){
                $(".video-intro-container-video").removeClass("hidden");
                var offset = $(this).offset();
                var left = offset.left;
                var top = offset.top;
                var height = $(this).height();
                var width = $(this).width();
                var container_height = $(".video-intro-container-video").outerHeight();
                var container_width = $(".video-intro-container-video").outerWidth();
                var window_with = $( window ).width();
                /*
                *
                */
                var container = $(".video-intro-container-video");
                var data = $(this).find(".video-intro-data");
                var price =  data.data("price" );
                var title = data.data("title" );
                var cat = data.data("cat" );
                var src = data.data("src" );
                var type = data.data("type" );
                container.find(".video-intro-price").html(price);
                container.find(".video-intro-title").html(title);
                container.find(".video-intro-category").html(cat);
                /*
                * Video Youtube
                */
                if( type == "youtube" ) {
                    $(".video-intro-container-video .video-intro-video-image").html('<iframe class="mfp-iframe" src="//www.youtube.com/embed/'+src+'?autoplay=1&loop=1" frameborder="0" allowfullscreen=""></iframe>');
                }else if( type == "mp4") {
                    $(".video-intro-container-video .video-intro-video-image").html('<video autoplay loop><source src="'+src+'" type="video/mp4"></video>');
                } else if( type == "map" ) {
                    $(".video-intro-container-video .video-intro-video-image").html('<iframe class="mfp-iframe" src="//maps.google.com/maps?q='+src+'&output=embed&hl=en&t=v&hnear='+src+'" frameborder="0" allowfullscreen=""></iframe>');
                }else if( type == "vimeo") {
                    $(".video-intro-container-video .video-intro-video-image").html('<iframe class="mfp-iframe" src="//player.vimeo.com/video/'+src+'?autoplay=1&loop=1&title=0&byline=0&portrait=0" frameborder="0" allowfullscreen=""></iframe>');
                }else {
                    $(".video-intro-container-video .video-intro-video-image").html('<img src="'+src+'" alt="">');
                }
                if( window_with > ( left  + width + container_width ) ) {
                    $(".video-intro-container-video").css("left",left  + width );
                }else{
                    $(".video-intro-container-video").css("left",left  - container_width );
                }
                console.log( container_height );
                $(".video-intro-container-video").css("top",(height/2));
    
    			$(".video-intro-container-video").css("position","fixed");
    
            },
            out : function(e){
                $(".video-intro-container-video").addClass("hidden");
                $(".video-intro-container-video .video-intro-video-image").html("");
            }
        }
        video_intro.init();
    })(jQuery);
    

    Regards,
    Dima

    Hello Dima,
    You are the best! Thank you very much! Really. This work 😀
    Thank you very, very much.
    Should I add this code with every update?
    Regards and thank you very much,
    Agunia

    PS: I can now give 5 stars calmly 😀

    Plugin Author Dima Holovnia

    (@dholovnia)

    Agunia,

    This is added to the plugin settings. So after update it will continue working. You can update the plugin without worries.

    Regards,
    Dima

    In all, logical.
    Thank you again. thank you very much!
    Thank you and thread is resolved.
    Regards,
    Agunia

    PS: I’ve translated the plugin to you.

    Plugin Author Dima Holovnia

    (@dholovnia)

    Agunia,

    Thank you for the translation. We will check it and add to the plugin asap.

    Regards,
    Dima

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘WooCommerce Load More Products and On Mouseover’ is closed to new replies.