title: AngularJS code works on Firefox but not Chrome
body: <p>I got a simple code allowing a user to enter a youtube URL in an input box, and it displays the embed video. Everytime you enter a new url, it gets listed in a playlist below. If you click on an item on the playlist, the video switches to the new url.</p>
  
  <p>You can copy paste this code, it works out of the box on Firefox, but in Chrome, <strong>the click on the playlist</strong> doesn't work.</p>
  
  <p>I can't understand why as there is no error (and I'm NOT using the file:// protocol so this is not the problem, I use a server):</p>
  
  <pre><code>&lt;!DOCTYPE html&gt;
      &lt;html ng-app='myApp'&gt;
        &lt;head&gt;
          &lt;meta charset="utf-8" /&gt;
          &lt;title&gt;
              Player simple
          &lt;/title&gt;
          &lt;script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.4.7/angular.min.js"&gt;&lt;/script&gt;
  
          &lt;script&gt;
          function onYouTubePlayerReady(){
              document.getElementById("ytplayer").playVideo();
          };
  
          angular.module('myApp', [])
  
  
          .factory("playlist", function($sce){
  
                  var embedUrl = 'https://www.youtube.com/v/{{id}}?version=3&amp;enablejsapi=1';
  
                 var service = {};
                 service.videos = [];
                 var currentVideo;
                 service.addVideo =  function(videoUrl){
                      var res = /youtube\.com\/watch\?v=([^&amp;]+)/.exec(videoUrl);
                      var url = embedUrl.replace("{{id}}", res[1]);
                      service.videos.push(url);
                      if (service.videos.length == 1){
                          service.currentVideo = $sce.trustAsResourceUrl(service.videos[0]);
                      }
                  };
  
                  service.playVideo = function(i){
                      console.log(i, service.videos[i])
                      service.currentVideo = $sce.trustAsResourceUrl(service.videos[i]);
                  }
  
                  return service;
          })
  
  
          .controller('Controlleur', function($scope, playlist) {
              $scope.playlist = playlist;
          });
  
          &lt;/script&gt;
  
      &lt;/head&gt;
  
      &lt;body  ng-controller="Controlleur"&gt;
          &lt;div&gt;
              &lt;object width="640" height="360" ng-show="playlist.currentVideo" &gt;
                &lt;param name="movie" value="https://www.youtube.com/v/M7lc1UVf-VE?version=3"&gt;&lt;/param&gt;
                &lt;param name="allowFullScreen" value="true"&gt;&lt;/param&gt;
                &lt;param name="allowScriptAccess" value="always"&gt;&lt;/param&gt;
                &lt;embed ng-src="{{playlist.currentVideo}}" type="application/x-shockwave-flash" allowfullscreen="true" allowScriptAccess="always" width="640" height="360" id="ytplayer"&gt;&lt;/embed&gt;
              &lt;/object&gt;
          &lt;/div&gt;
          &lt;div&gt;
              &lt;form ng-submit="playlist.addVideo(playlist.addedVideo)"&gt;
                  &lt;p&gt;&lt;input type="text" ng-model="playlist.addedVideo"&gt;&lt;button&gt;Add&lt;/button&gt;&lt;/p&gt;
              &lt;/form&gt;
              &lt;ul&gt;
                  &lt;li ng-repeat="video in playlist.videos"&gt;
                      &lt;a href="#" ng-click="playlist.playVideo($index)"&gt;{{video}}&lt;/a&gt;
                  &lt;/li&gt;
              &lt;/ul&gt;
          &lt;/div&gt;
  
      &lt;/body&gt;
  
      &lt;/html&gt;
  
      &lt;/body&gt;
      &lt;/html&gt;
  </code></pre>