My site uses javascript which reads youtube video ID's from an array. In the format:
1: 'A8JsRx2loix',
2: 'XFGAQrEUaes',
3: 'qX9FSZJu44s'
Whats the best way to take a list of urls like
http://www.youtube.com/watch?feature=player_detailpage&v=bCJ-qARb2M0
http://www.youtube.com/watch?feature=player_detailpage&v=bCJ-qAswdM2
http://www.youtube.com/watch?feature=player_detailpage&v=bCJ-sh7b2M0
and extract the 11 digit video ids, putting them in the given format above.
NOTE: the urls can be in different formats, for example when they are in playlists.