Skip to content

Instantly share code, notes, and snippets.

@davidbanham
Created October 16, 2012 23:36
Show Gist options
  • Save davidbanham/3902771 to your computer and use it in GitHub Desktop.
Save davidbanham/3902771 to your computer and use it in GitHub Desktop.
RSS fetch
function fetchRSS() {
$.ajax({
url: document.location.protocol + '//ajax.googleapis.com/ajax/services/feed/load?v=1.0&num=10&callback=?&q=http%3A%2F%2Fblog.counter-strike.net%2Findex.php%2Fcategory%2Fmotd%2Ffeed%2F',
dataType: 'json',
success: function(data) {
var post = data.responseData.feed.entries[0];
$('.title').text(post.title);
$('#post_content').html(post.content);
}
});
}
fetchRSS();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment