javascript - grab a youtube playlist from a url -
i using function fetches video based on video id. how fetch playlist url . function use fetch video based on id :
var ytid = url.match("[\\?&]v=([^&#]*)");
here playlist:
http://www.youtube.com/playlist?list=pl1w1q3fl4pmhqxjaomvwqwf6qsnjtrn-3
this playlist (at lease me):
http://www.youtube.com/course?category=university%2fengineering&feature=edu&list=ec6f144cf03cb2381b
the list id of both can parsed little modification of regex:
var listid = url.match("[\\?&]list=([^&#]*)");
Comments
Post a Comment