Search…

X3 Photo Gallery Support Forums

Search…
 
lucaonline
Topic Author
Posts: 20
Joined: 18 Oct 2016, 03:40

Placing a button on top of the Video Intro Page

07 Feb 2021, 05:23

Hello Community, I need some help :)

Is ist possible to place a button with a Link on top of the Video Intro?
Check: www.olympiagr.de

I need a Copy of the menu button "Lieferservice" (maybe renamed) in the middle of the the Screen as soon as you open the Website, right when the Video starts to load.

Thanks!
 
User avatar
mjau-mjau
X3 Wizard
Posts: 13993
Joined: 30 Sep 2006, 03:37

Re: Placing a button on top of the Video Intro Page

07 Feb 2021, 05:39

There might be a few ways to go about this, but the easiest is probably to just inject a link with Javascript. In the home page, go to Settings > Page, scroll down and expand Advanced, and add the following to Page Javascript:
Code
setTimeout(function(){
  var video = document.getElementsByClassName('startpage-video')[0];
  if(!video) return;
  video.insertAdjacentHTML('afterbegin', '<a href="/Lieferservice/" class="button" style="z-index:3; top: 50%">Lieferservice</a>');
  video.style.textAlign = 'center';
}, 100);