I have a mysql table that has two fields - an identifier number, and text based url's stored in it of locations of some mp4 videos. I want to make a very simple html5 video player that when opened, looks at the database, loads the queue, and starts playing. when one song ends, it loads the next one in the list.
I'm pretty proficient with php and mysql, but what's stumping me is what code to alter on the html5 video player to get it to move to the next song in the database when the current song ends. basically in pseudo code :
(php/mysql) select idNum, URL from tracklist
HTML5 video source = first URL in the list
play the video
function (video's over) get the next url using ajax or something (???) swap out the player's source keep playing with as little a gap as possible. rinse and repeat :-)
simple really. just dont quite understand how to harness the html5 video and make it play nice with php. help!