3
1
Back

Elseif (strpos($alt_text, $title_text) !== false){ // there's both alt and title texts, they're both different, use both. $alt_element = $doc->createElement("i", $title_text); } elseif (strpos($alt_text, $title_text) !== false){ // there's both alt and title texts, they're both different, use both. } elseif (strpos($article['link'], 'threepanelsoul.com/2') !== FALSE) { elseif (strpos($article['link'], 'polyinpictures.com/comic/') !== FALSE) { $article['content'] .= "ID: " . $img->getAttribute('title') . ""; } //noop } // Dead Philosophers elseif (strpos($article['link'], 'dead-philosophers.com/?p') !== FALSE) { $xpath = $this->get_xpath_dealie($article['link']); elseif (strpos($article['link'], 'dilbert.com/strip/') !== FALSE) { $doc = new DOMDocument(); $doc->loadHTML($article['content']); $xpath = $this->get_xpath_dealie($article['link']); $article['content'] = $this->get_img_tags($xpath, "//div[@id='cc-comicbody']//img", $article); } // Eat That Toast bog-standard example // Breaking Cat News elseif (strpos($article['link'], '//theoatmeal.com/comics/') !== FALSE) { $xpath = $this->get_xpath_dealie($article['link']); $article['content'] = $img_tag . $article['content']; // $article['content'] = $this->get_img_tags($xpath, "//img[starts-with(@src, '/comics/') and @class='comic_image']", $article); } // CTRL+ALT+DEL Sillies elseif (strpos($article['link'], 'https://web3isgoinggreat.com/single/') !== FALSE) { $xpath = $this->get_xpath_dealie($article['link']); // $xpath = $this->get_xpath_dealie($article['link']); $article['content'] = preg_replace('#(/[0-9-]+)-150x150\.gif#', '$1.gif', $article['content']); $article['content'] = $this->get_img_tags($xpath, "//img[starts-with(@src, '/comics/') and @class='comic_image']", $article); // $xpath = $this->get_xpath_dealie($article['link']); $article['content'] = $this->get_img_tags($xpath, "//div[@id='comic']/img", $article); } Various updates, additions elseif (strpos($article["link"], "poorlydrawnlines.com/comic/") !== FALSE ) { // Something Positive if (strpos($article['link'], 'eatthattoast.com/comic/') !== FALSE) { $xpath = $this->get_xpath_dealie($article['link']); // Girls with Slingshots elseif (strpos($article['link'], 'dilbert.com/strip/') !== FALSE) .

New Pull Request