function getFeed(feedURL,divName,numFeeds,includeSummary) {
// Arguments:
//   feedURL - the feed URL (Atom/RSS)
//   divName - the name of the "div" (id) where to dump the info
//   numFeeds- number of items to grab from the feed
//   includeSummary - zero (yes, include) or one (don't) include the summary
//                    from the feed.
//
jQuery.jGFeed(feedURL,function(feeds){
  var i=0;

  // Check for errors
  if(!feeds){
    // there was an error
    return false;
  }
  // do whatever you want with feeds here
  for(i=0; i<feeds.entries.length; i++){
    var entry = feeds.entries[i];
    var markup = '<div class="rssEntry"><a href="'+entry.link+'"><h3>' + entry.title + '</h3><h4>'+entry.publishedDate+'</h4></a>';
    if (includeSummary) {
        markup += '<p>' + entry.contentSnippet + '</p>';
    }
    markup += '</div>';
    // Entry title
    jQuery(divName).append(markup);
  }
return true;
}, numFeeds);

}

function getFeeds() {
    getFeed('http://www.military.com/news/rss/headlines.xml','#thefeed',3,0);
    getFeed('http://www.military.com/news/rss/headlines.xml','#milfeed',10,1);
    getFeed('http://www.defenselink.mil/news/afps2.xml','#thefeed2',3,0);
    getFeed('http://www.defenselink.mil/news/afps2.xml','#linkfeed',10,1);
    getFeed('http://militarytimes.com/rss_news.php','#thefeed3',3,0);
    getFeed('http://militarytimes.com/rss_news.php','#fortfeed',10,1);
    getFeed('http://cmrnotes.org/atom.xml','#thefeed4',3,0);
    getFeed('http://cmrnotes.org/atom.xml','#deployfeed',10,1);
}
