lightcase icon indicating copy to clipboard operation
lightcase copied to clipboard

Autoplay not working without any trigger link

Open alicankablan opened this issue 6 years ago • 1 comments

My html video is not playing auto at document ready

Here is my html : <video src="myvideo.mp4" width="800" height="450" poster="" preload="auto" controls="controls" autobuffer="true" autoplay="autoplay" onended="lightcase.close();" style="width: 800px; height: 450px; max-width: 800px; max-height: 492px;"></video>

     function Html5Video() {
        lightcase.start({
            video: {
                width: 800,
                height: 450,
                poster: '',
                preload: 'auto',
                controls: true,
                autobuffer: true,
                autoplay: true,
                loop: false,
                onended: 'lightcase.close();'
            },
            href: 'myvideo.mp4',
            caption: 'caption 123',
            title: 'title 123',
          
            onFinish: {
                autoClose: function () {
                    setTimeout(function () {
                        lightcase.close();
                    }, 15000);
                }
            }
            // more options like width, height, etc.
        });
    }

alicankablan avatar Dec 05 '18 10:12 alicankablan

Hi! Are you sure this is an issue of lightcase rather than it is something wrong with your video params and attributes? Try to embed and autoplay your video outside of the lightcase first to make sure this is an issue of this plugin.

Thanks

cbopp-art avatar Dec 06 '18 13:12 cbopp-art