Hi guys,
I am trying to build a simple web app that takes data from database, converts it into jason and inserts the data into a veriable that should act as a playlist.
I want to make the veriable called "songs" to be equals the result and insert it into ytplayer_playlist.
Any guides will be very helpfull!
var songs;
function addsongs(event) {
$.ajax({
url: 'post.php',
success: function (response) {
var url="http://localhost/xampp/websites/youtubeAPI/post.php";
$.getJSON(url,function(data){
$.each(data.members, function(i,song){
result = (song.SongUrl);
console.log(result);
});
});
}
});
}
ytplayer_playlist.push('tGvHNNOLnCk');