mirror of
https://github.com/RSS-Bridge/rss-bridge.git
synced 2025-08-03 09:35:57 +02:00
bridges: use BridgeAbstract::getSimpleHTMLDOM
instead of BridgeAbstract::file_get_html Signed-off-by: Pierre Mazière <pierre.maziere@gmx.com>
This commit is contained in:
parent
f43bbda83e
commit
3c0d13c1bb
121 changed files with 1212 additions and 396 deletions
|
@ -9,7 +9,7 @@ class CADBridge extends BridgeAbstract{
|
|||
}
|
||||
|
||||
private function CADExtractContent($url) {
|
||||
$html3 = $this->file_get_html($url);
|
||||
$html3 = $this->getSimpleHTMLDOM($url);
|
||||
|
||||
// The request might fail due to missing https support or wrong URL
|
||||
if($html3 == false)
|
||||
|
@ -27,7 +27,6 @@ class CADBridge extends BridgeAbstract{
|
|||
default:
|
||||
return 'Daily comic not released yet';
|
||||
}
|
||||
|
||||
$img = implode ($url2[0]);
|
||||
$html3->clear();
|
||||
unset ($html3);
|
||||
|
@ -45,7 +44,7 @@ class CADBridge extends BridgeAbstract{
|
|||
return $string;
|
||||
}
|
||||
|
||||
$html = $this->file_get_html('http://cdn2.cad-comic.com/rss.xml') or $this->returnServerError('Could not request CAD.');
|
||||
$html = $this->getSimpleHTMLDOM('http://cdn2.cad-comic.com/rss.xml') or $this->returnServerError('Could not request CAD.');
|
||||
$limit = 0;
|
||||
|
||||
foreach($html->find('item') as $element) {
|
||||
|
@ -67,4 +66,4 @@ class CADBridge extends BridgeAbstract{
|
|||
return 3600*2; // 2 hours
|
||||
}
|
||||
}
|
||||
?>
|
||||
?>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue