Skip to content

Instantly share code, notes, and snippets.

@fideloper
Created October 20, 2011 23:14
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save fideloper/1302683 to your computer and use it in GitHub Desktop.
Save fideloper/1302683 to your computer and use it in GitHub Desktop.
Youtube public channel uploaded videos
//See more http://code.google.com/apis/youtube/2.0/developers_guide_protocol_api_query_parameters.html
$.ajax({
type:'GET',
dataType:'jsonp',
//url:'http://gdata.youtube.com/feeds/users/USERNAME/uploads?alt=json', //also usable, but less awesome
url:'http://gdata.youtube.com/feeds/api/videos',
data:{author:'USERNAME', v:2, orderby:'published', alt:'json', 'max-results':10},
success:function(data, textStatus, XMLHttpRequest) {
console.log(data);
},
error:function(eq, status, error) {
alert('error: '+status);
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment