diff --git a/public/ytembed.js b/public/ytembed.js index 28e23bf..3a979b6 100644 --- a/public/ytembed.js +++ b/public/ytembed.js @@ -7,7 +7,7 @@ document.getElementsByTagName('script')[0].parentNode.insertBefore(apiEmbed, doc function onYouTubePlayerAPIReady() { var youTubePlaceholders = document.getElementsByClassName('ytplaceholder'); for(var i = 0; i < youTubePlaceholders.length; i++) { - var videoURL = youTubePlaceholders[i].innerText; + var videoURL = youTubePlaceholders[i].innerHTML; var videoIDMaybe = videoURL.match(/[?&]v=([A-Za-z0-9\-_]+)(?:[?&]|$)/); youTubePlaceholders[i].innerText = ''; if(videoIDMaybe) {