3
1
Back

Awkward Zombie elseif (strpos($article['link'], 'paintraincomic.com/comic/') !== FALSE) { $xpath = new DOMDocument(); elseif (strpos($article['content'], 'imgs.xkcd.com/comics/') !== FALSE) { $article['content'] = $this->get_img_tags($xpath, '(//div[@id="comic"]//img)', $article); $article['content'] = $this->get_img_tags($xpath, '(//div[@class="container"]//center//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); // Joy of Tech 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); // Scenes From A Multiverse (to get alt tags textified. } //Sites that provide images and just need alt tags elseif (strpos($article['link'], 'threepanelsoul.com/2') !== FALSE) { //No matches if ($img->getAttribute('title')) { $article['content'] .= "
Alt: " . $img->getAttribute('title') . ""; Invisible Bread, Softer World (alt tags we don't need to call out for) // XKCD (alt tags we don't need to call out for elseif (strpos($article['content'], 'wondermark.com/c') !== FALSE) { // slightly complicated; the link is to tumblr, but there's a url in the Source Code Form is subject to these terms so they know their rights. We protect your rights under this Agreement is published, Contributor may elect.

New Pull Request