Are you first timer at lazacode.org? Why not join us and start exchange your programming knowledge with everyone. Register today!

Google Ad Manager - youtube video loop, click tracking and API settings

0 votes
24 views
added Jul 6 in Google tools by lcjr Second Warrant Officer (6,120 points)
<html> 
  <head>
    <script type="text/javascript">
    // Change the value of this string to your URL
    var clickTag = "https://www.chanel.com/my/";
    </script>
  </head>
	<body style="margin: 0px;"> 
    <a href="javascript:window.open(window.clickTag)" style="position:relative; display:inline-block;z-index: 2;">
      <div style="position:absolute;height:205px; width:110px; z-index:1;"></div>
      <div style="position:absolute;height:80px; width:100%; z-index:1;"></div>
      <div style="position:absolute;height:205px; width:110px; z-index:1;right:0px;"></div>
      <div style="position:absolute;bottom: 44px;left: 111px;height: 45px;width:80px;z-index:1;"></div> 
      <div id="player"></div>
      <div id="player2"></div>
    </a>
    <script>
      var tag = document.createElement('script');

      tag.src = "https://www.youtube.com/iframe_api";
      var firstScriptTag = document.getElementsByTagName('script')[0];
      firstScriptTag.parentNode.insertBefore(tag, firstScriptTag);

      var player, player2;
      
      
      function onYouTubeIframeAPIReady() {
        player = new YT.Player('player', {
          height: '250',
          width: '300',
          videoId: '3cmZLOnruoo',
                playerVars: {
                  start: 0,
                  end: 182,
                  loop: 1,
                  playlist: '3cmZLOnruoo',
                  control: 1,
                  modestbranding: 1,
                  // controls: 0,
                  fs: 0,
                  rel: '0',
                  iv_load_policy: '3'
                },
          events: {
            'onReady': onPlayerReady,
            'onStateChange': onPlayerStateChange
          }
        });
        
      }

      function onPlayerReady(event) {
        event.target.playVideo();
        event.target.mute();
      }

      function onPlayerStateChange(event) {
      }

    </script> 
  </body> 
</html>

 

Please log in or register to response this reference.

lazacode.org - Malaysia's programming knowledge sharing platform, where everyone can share their finding as reference to others.
...