Tagged: background video, vimeo video
-
AuthorPosts
-
July 24, 2018 at 12:31 pm #989141
As far as i know the advanced slider can do that for you.
see here a demo: https://webers-testseite.de/weber/
But this is a selfhosted small video, and only the newest browsers for mobile devices ( IOS11 with new Safari f.e.) will play that background video.On vimeo case : on sharing options you can see the embed options and press settings.
choose responsive and get rid of Author, Image and Title. Choose Autoplay and loop but no textlink !the code of your video will be:
<div style="padding:56.25% 0 0 0;position:relative;"><iframe src="https://player.vimeo.com/video/258140746?autoplay=1&loop=1&title=0&byline=0&portrait=0" style="position:absolute;top:0;left:0;width:100%;height:100%;" frameborder="0" webkitallowfullscreen mozallowfullscreen allowfullscreen></iframe></div><script src="https://player.vimeo.com/api/player.js"></script>
Very important now we change in that code something
1) That div will not work – and we do not need it – same thing with the script
2) Change positioning to relative !!!
3) width: 100vw and height: 56.25vw (on 16/9 videos)
4) give the iframe a class: vimeo (on vimeo it seems to be good to scale the iframe a bit to have no borders on full-width at very small screens)
Result:
<iframe class="vimeo" src="https://player.vimeo.com/video/258140746?loop=1&title=0&byline=0&portrait=0" style="position:relative;top:0;left:0;width:100vw;height:56.25vw;" webkitallowfullscreen="" mozallowfullscreen="" allowfullscreen="" frameborder="0"></iframe>
goto Advanced Layerslider make a new slider (responsive with width and height in the aspect ratio of 16/9)
add a video audio layer insert that code above and define that layer as background-video layer.see result here: https://webers-testseite.de/weber/archie/
do this to quick css:
iframe.vimeo { transform: scale(1.02); }
PPS: i have choosen the way over selfhosted video as background – because of GDPR ( DSGVO) reasons.
all big video hosters (youtube and vimeo) will send data from the visitors to their servers ( on minimum the IP) this is not allowes without an opt-in.July 26, 2018 at 10:56 am #990175February 1, 2019 at 8:23 pm #1061705Hi
I needed this same thing and after reading all the threads on this topic, went through the steps above in the advanced slider, but still cannot see the video on my mobile –even though I can see the video on your site just fine. Vimeo has a new parameter using “background=1” to disable all the controls and autoplay/loop the video to get around the restrictions of the browsers, which have changed a bit since this thread.My embed code is:
<iframe class="vimeo" src="https://player.vimeo.com/video/168191481?background=1&muted=1" style="position:relative;top:0;left:0;width:100vw;height:56.25vw;" webkitallowfullscreen="" mozallowfullscreen="" allowfullscreen="" frameborder="0"></iframe>
Both sites look fine for me in the chrome inspector for mobile.
any suggestions?- This reply was modified 5 years, 9 months ago by Munford.
February 4, 2019 at 5:11 am #1062486Hi,
Did you set the layer type to “Video/AUdio”? What happens when you remove the inline styling?
Best regards,
IsmaelFebruary 4, 2019 at 9:37 am #1062540HI thanks for responding!
I was able to get it working with that code, just a delay to see it on my phone.
the background=1 seems to do the trick.If I wanted a but more height on the mobile video, how can I do that?
NancyFebruary 5, 2019 at 3:31 pm #1063198Hi Ismael I hope you can help me with this.
My client wants it to be like this site: http://www.visuello.no. with the background video height changing on small screens to a portrait mode with a taller aspect ratio than on the pc. I tried changing the height paramenter in my advanced slider code to 100vw:
<iframe class="vimeo" src="https://player.vimeo.com/video/47299461?background=1&muted=1" style="position:relative;top:0;left:0;width:100vw;height:100vw;" webkitallowfullscreen="" mozallowfullscreen="" allowfullscreen="" frameborder="0"></iframe>
but that didn’t change anything, and I don’t want to mess up the display on PC (though I guess I could make a separate slider just for mobile). Is it possible to have the 16:9 vimeo video display at a more of a portrait mode on the mobile through i frame code and/or is there a way to make the container taller? I am just learning advanced slider and am not sure how to do this.
thanks for your help or maybe guenni007 has an idea how to do it, since it was his code I copied?
Nancy- This reply was modified 5 years, 9 months ago by Munford.
February 5, 2019 at 6:44 pm #1063242i would like to help you.
But i guess this will only work with a third party plugin.: Advanced WordPress Backgroundssee here a page in testing mode with youtube background video: https://webers-testseite.de/carinda/
Look with your devices to it and tell me if all works as you like to have it.
Afterwards i will give you support on thatFebruary 5, 2019 at 6:53 pm #1063244Hi Guenni
thanks so much for your help – you seem to know what you are doing.
That’s pretty much what we are looking for – I can see it on the chrome inspector but not on my phone. This was true with your other link above as well and with my video where I could see that the video loaded but only saw a still image, but after a day my video was fine, so I have to assume it works – seems to be a big delay.That is done with that plugin and not with the advanced layer slider, right?
The ALS is kind of overkill for what I am trying to do.thanks
NancyFebruary 5, 2019 at 7:21 pm #1063265All big Themes with drag and drop helper Tools have this problem. I looked for a Divi Solution for a customer and found a tut with that littel plugin above.
The trouble was to adapt it to the enfold-theme.
The Problem with video is that even if you have LTE Support on your mobile device – the RAM and ROM on Mobile Phones is limited.
On my webdesign homepage that is only a self-hosted very small Video. This will work propper. And then layerslider is a good solution because it is hard to get it responsive – even for mobiles too.February 5, 2019 at 7:24 pm #1063267A next topic in this connection is the GDPR compliance. One must therefore pay attention to the fact that the visitors of the side can open the corresponding sides only if one has agreed to it by means of Opt-In solution. In any case with Vimeo and Youtube implementation.
February 5, 2019 at 7:44 pm #1063275does that plugin work with the classic editor in enfold? I am not using gutenburg.
and if I understand you, the advanced layer slider can’t really be adapted to mobile in the same way as I need it?in regards to GDPR – is it enough to have a compliance checkbox on the page where I have the background video?
I don’t see anything on visuello.no site. That site is built in Craft CMS, which I am not familiar with.thanks
NancyFebruary 5, 2019 at 10:19 pm #1063361Yes this plugin works with alb or classic editor.
But you have to insert that shortcode via Code-Block element.
_________
If you follow the legal text exactly, no information ( yes also an IP is this ) may take place before the Opt-In. In my opinion the homepage ( landing page ) is an unsuitable place for a Background Youtube or Vimeo movie. Because as soon as a page is called, the transmission takes place in the direction of Google (in the case of Youtube). Ideally it would be if first a page is opened without Background Film (self-hosted films excluded) on which the Opt-In procedure is initiated. E.g. by a link to the privacy policy page.
But this is up to you how you proceed. A wave of lawsuits has probably failed to materialize.February 6, 2019 at 12:01 pm #1063566Thanks for all the information. I will talk to my client about it. You wrote in an earlier post that you couldn’t use self-hosted videos for the mobile video background, right?
I tested making a slider in ALS with a responsive canvas size more 1:2 instead of 16:9 (that is, a vertical format) and then just using that for the mobile. Seems to work, unless I am missing something? It does load a bit slowly for me but not sure if that’s due to the sliders or something on my end.
QUESTION: is it possible to have the background video start playing at a random point every time a visitor views the page?
thanks for your help
Nancy- This reply was modified 5 years, 9 months ago by Munford.
February 11, 2019 at 7:57 am #1065338Hi,
I think it’s possible with youtube videos using the “start” parameter, but it will require custom modifications that are beyond the scope of support.
// https://developers.google.com/youtube/player_parameters#start
Best regards,
Ismael -
AuthorPosts
- You must be logged in to reply to this topic.