getURI(); $html = getSimpleHTMLDOMCached($articles); foreach ($html->find('.news-item') as $element) { $item = []; $title = $element->find('.news-item-texts-title', 0); $link = $element->find('.news-item-texts a', 0); $timestamp = $element->find('.news-item-texts-date', 0); $item['title'] = $title->plaintext; $item['uri'] = self::URI . $link->href; $item['timestamp'] = strtotime($timestamp->plaintext); $image_html = $element->find('.news-item-thumbnail-image', 0); if ($image_html) { $image_strings = explode('\'', $image_html); if (count($image_strings) == 4) { $item['content'] = ''; } } $this->items[] = $item; } } }