3
1
Back

$base_url=NULL) { function get_img_tags($xpath, $query, $article){ $entries = $xpath->query("//span[@class='rss-content']"); foreach ($entries as $entry) { $article['content'] = $this->get_img_tags($xpath, "//div[@id='comic-img']//img", $article); } // Jesus & Mo elseif (strpos($article['link'], 'polyinpictures.com/comic/') !== FALSE) { elseif (strpos($article['link'], 'dilbert.com/strip/') !== FALSE) { Clean up code formatting; added a few comics; standardized appending alt/title text under images (extra useful for non-browser users $host->add_hook($host::HOOK_RENDER_ARTICLE_CDM, $this); $host->add_hook($host::HOOK_RENDER_ARTICLE, $this); } function rel2abs($rel, $base) { if (preg_match("@.*?(.*)@", $article['content'], $matches)) { $img = preg_replace("@height=\"\d+\"@", "", $img); $article['content'] = $this->get_img_tags($xpath, '//p[@class="Maintext"]//img[contains(@src, "joyimages")]', $article); // And get blog entry $entries = $xpath->query("//div[@id='blarg']/div[last()]"); foreach ($entries as $entry) { $article['content'] = $this->get_img_tags($xpath, '//p[@class="Maintext"]//img[contains(@src, "joyimages")]', $article); } // Camp Weedonwantcha elseif (strpos($article['link'], 'amultiverse.com/comic/') !== FALSE) { $xpath = $this->get_xpath_dealie($article['link']); $article['content'] = $this->get_img_tags($xpath, "//div[@id='comic-1']//img", $article); } function mangle_article($article) { // only keep everything starting at the first if(preg_match("@.*(

New Pull Request