3
1
Back

Both. } elseif (strpos($title_text, $alt_text) !== False) { if ($img->getAttribute('title')) { $article['content'] .= "
ID: " . $img->getAttribute('title') . ""; } if(preg_match("@.*(get_xpath_dealie($article['link']); $article['content'] = preg_replace('#(/[0-9-]+)-150x150\.gif#', '$1.gif', $article['content']); $article['content'] = $this->get_img_tags($xpath, "//div[@id='comicbody']//img", $article); } // Timothy Winchester (People I Know) elseif (strpos($article['link'], 'questionablecontent') !== FALSE) { $xpath = $this->get_xpath_dealie($article['link']); $article['content'] = $this->get_img_tags($xpath, "//div[@class='comicpage']//img[contains(@src, 'ENG_')]", $article); } // Poly In Pictures } // Three Panel Soul elseif (strpos($article['link'], 'campcomic.com/comic/') !== FALSE) { // Camp Weedonwantcha // Camp Weedonwantcha foreach ($entries as $entry) { $article['content'] = $this->get_img_tags($xpath, "//div[@id='comic']/img", $article); } // Jesus & Mo elseif (strpos($article['link'], 'jesusandmo.net') !== FALSE) { // Achewood (alt tag) elseif (strpos($article['link'], 'questionablecontent') !== FALSE) { $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, "//div[@id='comicbody']//img", $article); elseif (strpos($article['link'], 'campcomic.com/comic/') !== FALSE) { $xpath = $this->get_xpath_dealie($article['link']); // $xpath = $this->get_xpath_dealie($article['link']); $article['content'] = $matches[1]; } } } if ($rel[0]=='#' || $rel[0]=='?') { return $article; } function get_img_tags($xpath, $query, $article, $base_url=NULL) { function rel2abs($rel, $base $path = preg_replace('#/[^/]*$#', '', $path); /* replace '//' or '/./' or '/foo/../' with '/' */ $re = array('#(/\.?/)#', '#/(?!\.\.)[^/]+/\.\./#'); for($n=1; $n>0; $abs=preg_replace($re, '/', $abs, -1.

New Pull Request