returnError('Could not request CAD.', 404); $limit = 0; foreach($html->find('item') as $element) { if($limit < 3) { $item = new \Item(); $item->title = $element->find('title', 0)->innertext; $item->uri = CADUrl($element->find('description', 0)->innertext); if ($item->uri != 'notanurl') { $item->timestamp = strtotime($element->find('pubDate', 0)->plaintext); $item->content = ''; $this->items[] = $item; $limit++; } } } } public function getName(){ return 'CAD Bridge'; } public function getURI(){ return 'http://www.cad-comic.com/'; } public function getCacheDuration(){ return 3600*2; // 2 hours // return 0; } }