1 Reply Latest reply on Aug 16, 2017 9:54 PM by José Jesús Pérez Rivas

    How to add an Image Link on top of a Background image


      Guys, trying to add an image link on top of a background image. When the image link that is on top of the background image is tapped it activates a video embed. See attached for a visual. Ideas are

      greatly appreciated. Untitled.jpg

        • 1. Re: How to add an Image Link on top of a Background image
          José Jesús Pérez Rivas Adobe Community Professional (Moderator)

          Hi KeithKrugh


          You can add an "onclick" event to the layer that containing the background image. In that event you can open a video player inside your app or a YouTube iframe for example.


          Your code might look like this:



          document.querySelector('#id_div_background').onclick = function(){

               document.querySelector('#id_div_video').classList.remove ('hide');

               document.querySelector('#id_div_video iframe').src="https://.....";




          <div id="id_div_background" class="content"></div>

          <div id="id_div_video" class="content hide"><iframe src=""></iframe></div>







          #id_div_video iframe{


               height: 300px}


               position: absolute;

               top: 0px;

               bottom: 0px;

               width: 100%}


               display: none}


          I hope it helps you