init(); $feed->handle_content_type(); foreach ($feed->get_items() as $item) { $output = "
" . "

get_permalink() . "\" title=\"" . $item->get_title() . "\" class=\"articleTitle\">" . $item->get_title() . "

"; if ($category = $item->get_category()) { $output .= $category->get_label() . " "; } $output .= $item->get_date(); $output .= "

"; $output .= shorten($item->get_description(), 600) . "

" . "get_permalink() . "\" title=\"Read More\" class=\"btn btn-info\">Read More"; $output .= "

"; echo $output; }//end foreach($feed->get_items() as $item) }//end getFeed($feed_url) public function importRSSFeeds($xmlFile, $DB) { $xml = simplexml_load_file($xmlFile); foreach($xml as $feed) { foreach($feed->outline as $thisFeed) { if($thisFeed->outline['type'] == "rss") { $DB->addFeedToDatabase($thisFeed['text'], $thisFeed['title'], "folder", "", ""); foreach($thisFeed->outline as $feeds) { $DB->addFeedToDatabase($feeds['text'], $feeds['title'], $feeds['type'], $feeds['xmlUrl'], $feeds['htmlUrl']); } echo "

"; } } } } //end importRSSFeeds($xmlFile) public function getFeedList() { $lastType = ""; $DB = new Database(); $result = $DB->returnFeedList(); foreach($result as $individualFeed) { if($individualFeed['type'] == "folder") { if ($lastType == "rss") { echo ""; } echo "
  • " . $individualFeed['title'] . "
  • "; echo "
    "; echo "