@celsoazevedo
Sorry I don’t understand your question. With ‘Lazy Load for Video and iFrames’ switched OFF – it will have no effect.
Are you saying Lazy Load is being applied to your self hosted video and preventing the video downloading even with that option switched OFF? In your replicate issue example what happens if you Switch OFF lazy load completely from the admin panel?
Hey @a3rev,
There are no problems downloading the file, videos load fine.
Only videos where I use preload=”none” are affected: the download should start only when we press “play”, but when this plugin is active (even with the video section switched OFF) the download starts when the video becomes visible.
A quick video were you can see the preloading: https://www.celsoazevedo.com/files/2018/a3-lazy-load.mp4
I’ve created this test page so you can test it yourself: https://www.celsoazevedo.com/files/test01/
Why is this a problem? Well, the browser downloads a few MB even when users don’t watch the video.
@celsoazevedo
Thanks for the video and the link to the test page – I think I see the issue – a3 Lazy Load does not support video added by WP Shortcode
VIDEO LAZY LOAD
a3 Lazy Load supports all WordPress video Embeds including Youtube, Vimeo and HTML5 video – for a full list see the WordPress Codex Embeds list. The WordPress embed method of copying and pasting the video url into posts and pages content area is fully supported. Note – embed video by WordPress shortcode is not supported.
I think there is a conflict there. Please try embedding it by one of the supported methods – or alternatively and i do not know if this will work by adding the video class to the Skip Video Class section that shows with that Video options turned on. It looks like this.
https://i.gyazo.com/8ecceb2f85553fad7506eb90ccdbbc55.png
Please give those a try and see how you go.
Regards
Steve
I think I see the issue – a3 Lazy Load does not support video added by WP Shortcode
I “ignored” that part because I was using this plugin only for images and to be honest my brain failed to link this issue with that limitation. My bad 😛
I think there is a conflict there. Please try embedding it by one of the supported methods – or alternatively and i do not know if this will work by adding the video class to the Skip Video Class section that shows with that Video options turned on.
Everything seems to work well with direct links to MP4 files or YouTube videos.
I’ve used before the “Skip Videos Classes” option with the default “wp-video” class and just tested with other classes on my test page (with only this plugin active, just to be sure). Sadly it doesn’t fix my issue: preload still occurs when scrolling videos with preload=”none”.
I already have a considerable number of posts with videos (all using the shortcodes generated by the WordPress editor/gallery), so it’s not easy to replace shortcodes (mp4+webm, default image, etc) with direct links.
Anyway, this shouldn’t affect too many users as most people don’t host videos themselves, but it’s something that could be improved. For now I’ll use a different plugin on the sites where I use WordPress shortcodes for videos.
Thanks for your work and fast support!
Hello Celso @celsoazevedo
Released version 1.8.5 this morning and 1.8.6 since then with a fix for an issue we created in 1.8.5)
Went back and looked at your video and the shortcode and we where able after some time to be able to recreate the issue on a local.
What was happening was that a3 lazy Load was loading the placemarker then calling the videos to load. We added this fix in version 1.8.5
* Fix – If videos embed have preload=none do not call video load from a3 Lazy Load. Thanks to Celso Azevedo @celsoazevedo for an excellent bug report which enabled us to replicate the issue.
We have tested it as well as we can and works a treat – if you can give it a try on your site and let me know how it works for you – that would be good.
Regards
Steve
Hey @a3rev,
Just tested with 1.8.7 and it’s working well.
Thanks for fixing this issue!