public function get_enclosures() { return null; } public function get_categories() { return null; } } $feed = new DummySingleItemFeed($url); } //////////////////////////////////////////// // Create full-text feed //////////////////////////////////////////// $output = new FeedWriter(); $output->setTitle(strip_tags($feed->get_title())); $output->setDescription(strip_tags($feed->get_description())); $output->setXsl('css/feed.xsl'); // Chrome uses this, most browsers ignore it if ($valid_key && isset($_GET['pubsub'])) { // used only on fivefilters.org at the moment $output->addHub('http://fivefilters.superfeedr.com/'); $output->addHub('http://pubsubhubbub.appspot.com/'); $output->setSelf('http://' . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI']); } $output->setLink($feed->get_link()); // Google Reader uses this for pulling in favicons if ($img_url = $feed->get_image_url()) { $output->setImage($feed->get_title(), $feed->get_link(), $img_url); } ////////////////////////////////////////////
public function get_enclosure($key = 0, $prefer = null) { return null; } public function get_enclosures() { return null; } } $feed = new DummySingleItemFeed($url); } //////////////////////////////////////////// // Create full-text feed //////////////////////////////////////////// $output = new FeedWriter(); $feed_title = $feed->get_title(); //if (function_exists('mb_convert_encoding')) { // $feed_title = mb_convert_encoding($feed_title, 'HTML-ENTITIES', "UTF-8"); //} /* $ori_feed_title = $feed_title; //if (strpos($url, "www.linuxeden.com") !== FALSE) { if (key_exists($url, $options->convert_encoding)) { //if (function_exists('iconv')) { //$feed_title = iconv("gb2312", "UTF-8//IGNORE", $feed_title); //$feed_title = mb_convert_encoding($feed_title, 'HTML-ENTITIES', "gb2312"); //} //$feed_title = mb_convert_encoding($feed_title, 'HTML-ENTITIES', "UTF-8"); //$feed_title = iconv("gb2312", "UTF-8//IGNORE", $feed_title); if (function_exists('mb_convert_encoding')) {