3
1
Back

Comic-fetching.', ' '); ' ' ); } function get_img_tags($xpath, $query, $article) { $entries = $xpath->query("//div[@id='signoff-wrapper']"); } //Sites that provide images and just need alt tags textified. If(ADD_IDS){ $article = $this->alt_textify($article); if (ADD_IDS) { $imgs = $xpath->query('//img'); //doesn't get simpler than this foreach($imgs as $img){ $article['content'] .= "

" . $entry->textContent . "

"; } } // Something Positive elseif (strpos($article['link'], 'cad-comic.com/cad/') !== FALSE) { $xpath = $this->get_xpath_dealie($article['link']); $img_tag = $this->get_img_tags($xpath, "//div[@id='comic']//img", $article); } 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_ARTICLE_FILTER, $this); $host->add_hook($host::HOOK_RENDER_ARTICLE_CDM, $this); $host->add_hook($host::HOOK_RENDER_ARTICLE, $this); } function mangle_article($article) { // Timothy Winchester (People I Know) // Timothy Winchester (People I Know) elseif (strpos($article['link'], 'breakingcatnews.com/comic/') !== FALSE) { $xpath = $this->get_xpath_dealie($article['link']); $article['content'] = $this->get_img_tags($xpath, "//img[starts-with(@src, 'sp') and contains(@src, 'png')]", $article); Created by editing arbitrary text (using size .

New Pull Request