rss-bridge/bridges/KoreusBridge.php
Pierre Mazière f1fb95b257 [core] extract BridgeAbstract methods to make them functions
- returnError, returnServerError, returnClientError ,debugMessage are
  moved to lib/error.php

- getContents, getSimpleHTMLDOM, getSimpleHTMLDOMCached are moved to
  lib/contents.php

Signed-off-by: Pierre Mazière <pierre.maziere@gmx.com>
2016-09-25 23:22:33 +02:00

22 lines
579 B
PHP

<?php
class KoreusBridge extends FeedExpander {
const MAINTAINER = "pit-fgfjiudghdf";
const NAME = "Koreus";
const URI = "http://www.koreus.com/";
const DESCRIPTION = "Returns the newest posts from Koreus (full text)";
protected function parseItem($item) {
$item = parent::parseItem($item);
$html = getSimpleHTMLDOMCached($item['uri']);
$text = $html->find('p.itemText', 0)->innertext;
$item['content'] = utf8_encode($text);
return $item;
}
public function collectData(){
$this->collectExpandableDatas('http://feeds.feedburner.com/Koreus-articles');
}
}