diff --git a/index.html b/index.html index a25de3c..77ba26b 100755 --- a/index.html +++ b/index.html @@ -28,7 +28,7 @@
- diff --git a/js/radio.js b/js/radio.js index 5006a9b..d2b2255 100644 --- a/js/radio.js +++ b/js/radio.js @@ -72,12 +72,11 @@ function getSongURL(MPDartist, MPDsong) function getYouTubeRequest(MPDfile) { var url = 'https://www.googleapis.com/youtube/v3/search'; var params = { - // part: 'id', + part: 'id', part: 'snippet', - key: '', + key: 'AIzaSyCfkMY2Nk3QwEh1Tjdqm-8GueBqOS5jgeI', q: MPDfile }; - $.getJSON(url, params, showResults); } @@ -87,4 +86,5 @@ function showResults(results) { YouURL = entries[0].id.videoId; document.querySelector('img[name="YouTubeThumb"]').setAttribute('src', thumb); document.querySelector('a[name="YouTubeURL"]').setAttribute('href', "https://www.youtube.com/watch?v="+YouURL); + console.log("https://www.youtube.com/watch?v="+YouURL); }