Pulling music from Itunes

The jukebox assignment requires you to come up with a selection of music that your users can play. In Spring 2015 a student,Abemelek Markos, pointed me to the Itunes API as a source of 30 second song samples from the Itunes api. After fiddling with the api a bit, I came up with a form based method for finding 30 second Itunes samples.

To use the form, browse to http://familybutton.mynmi.net/submitsong.html, submit the name of a band, and you may get lucky. If, for example, you submit the word 'stones', you get links to 200 music samples of music by the rolling stones.  Each song comes with a player button and artwork. Each song also generates a url that says Copy this url as in
Copy This Url: http://a966.phobos.apple.com/us/r1000/048/Music4/v4/9a/90/da/9a90da79-5e24-84ee-1af2-6b0b01f71bf4/mzaf_894175191745970460.plus.aac.p.m4a

There are two ways that you can put a selection of these 30 second clips to use with your jukebox.

    1. Copy everything from http: to .m4a at the end and paste it into the appropriate spot in your music player.
       For example, you could take the code <audio autoplay="true"><source src="twist.mp3" type="audio/mpeg"></audio> and substitute twist.mp3 for http://a966.phobos.apple.com/us/r1000/048/Music4/v4/9a/90/da/9a90da79-5e24-84ee-1af2-6b0b01f71bf4/mzaf_894175191745970460.plus.aac.p.m4a
    2. Copy everything from http: to .m4a at the end, paste into your browser's address window, and 'save as' to download the song. BTW, it probably would be a good idea to shorten the name of the song a bit.
      You could also right-click on any of the album covers and 'copy image url' if you wanted to use that art in your jukebox.
Print Friendly, PDF & Email