3
1
Back

Elseif (strpos($article["link"], "satwcomic.com/") !== FALSE) { $xpath = $this->get_xpath_dealie($article['link']); $article['content'] = $this->get_img_tags($xpath, '(//div[@id="comic"]//img)', $article); } Invisible Bread, Softer World (alt tags), Dinosaur Comics (alt tags+blog), CAD, attempt at OOTS (but that one fails due to referer checks elseif (strpos($article['link'], 'dead-philosophers.com/?p') !== FALSE) { $doc = new DOMXpath($doc); $imgs = $xpath->query('//img'); //doesn't get simpler than this foreach ($imgs as $img) { if ($doc === NULL) { if (preg_match("@.*?(.*)@", $article['content'], $matches)) { $img = preg_replace("@width=\"\d+\"@", "", $img); $img = $matches[1]; $img = preg_replace("@height=\"\d+\"@", "", $img); $img = preg_replace("@width=\"\d+\"@", "", $img); $img = preg_replace("@height=\"\d+\"@", "", $img); $img = preg_replace("@width=\"\d+\"@", "", $img); $article['content'] = $this->get_img_tags($xpath, '//p[@class="Maintext"]//img[contains(@src, "joyimages")]', $article); } // Jesus & Mo elseif (strpos($article['link'], 'dilbert.com/strip/') !== FALSE) { $article['content'] = $this->get_img_tags($xpath, "//div[@class='singleImage']/img[@class='magicfields']", $article); elseif (strpos($article['link'], 'www.geekculture.com/joyoftech/') !== FALSE) { $article['content'] = $this->get_img_tags($xpath, '(//div[@id="comicFrame"])', $article); Added The Trenches; yet more code style tweaking elseif (strpos($article["link"], "explosm.net/comics") !== FALSE) { $xpath = new DOMXpath($doc); $bread = $xpath->query("//a[contains(@href, 'bonus-panel')]")->item(0); $bread_page_url = $bread->getAttribute('href'); $xpath.

New Pull Request