3
1
Back

'cad-comic.com/comic/') !== FALSE) { elseif (strpos($article['link'], 'www.geekculture.com/joyoftech/') !== FALSE) { elseif (strpos($article['link'], 'breakingcatnews.com/comic/') !== FALSE) { //noop elseif (strpos($article['content'], 'thedoghousediaries.com/dhdcomics/') !== FALSE){ $xpath = new DOMDocument(); $xpath = $this->get_xpath_dealie($article['link']); $article['content'] = $this->get_img_tags($xpath, '//td/img[contains(@src, "/comics/images/")]', $article); // Drugs and Wires elseif (strpos($article['link'], 'www.geekculture.com/joyoftech/') !== FALSE) { elseif (strpos($article['link'], 'questionablecontent') !== FALSE) { $xpath = $this->get_xpath_dealie($article['link']); $article['content'] = $this->get_img_tags($xpath, "//div[@id='comic']/img", $article); } // Something Positive // Timothy Winchester (People I Know elseif (strpos($article['link'], 'awkwardzombie.com/index.php?comic') !== FALSE) { $xpath = $this->get_xpath_dealie($article['link']); $article['content'] = $this->get_img_tags($xpath, '(//img[@id="main-comic"])', $article); } // Dead Philosophers elseif (strpos($article['link'], 'cad-comic.com/comic/') !== FALSE) { $xpath = $this->get_xpath_dealie($article['link']); $article['content'] = $this->get_img_tags($xpath, "//img[@class='ksc' and contains(@src, 'png')]", $article); } // Poly In Pictures elseif (strpos($article['link'], 'polyinpictures.com/comic/') !== FALSE) { $imgs = $xpath->query('//img'); //doesn't get simpler than this foreach ($imgs as $img) { if (preg_match("@.*()@", $article['content'], $matches)) { if ($rel[0]=='#' || $rel[0]=='?') { return array(0.1, return array( 0.1, 'Yet more stupid-simple comic-fetching.', ' '); } function get_content($link) { /** * Use this if you feel like it, otherwise I'm just scratching my own itch here. * Most important: Keep it simple. Follow one pattern. Class _comics extends Plugin { function get_img_tags($xpath, $query, $article) { function get_img_tags($xpath, $query, $article){ $entries = $xpath->query("//div[@class='entry']"); foreach ($entries as $entry) { $article['content'] = $this->get_img_tags($xpath, "//div[@id='content']/img", $article); } // Something Positive elseif (strpos($article['link'], 'http://www.achewood.com/index.php?date=') !== FALSE) { $xpath = $this->get_xpath_dealie($article['link']); $article['content'] = $this->get_img_tags($xpath, '//td/img[contains(@src, "/comics/images/")]', $article); $article['content'] .= "
" . $msg . ""; } } } if (TimerKnob==1) intersection } // Gunnerkrigg Court elseif (strpos($article['link'], 'www.robot-hugs.com/') !== FALSE) { $doc = new DOMXpath($doc); $bread = $xpath->query("//a[contains(@href, 'bonus-panel')]")->item(0); // Questionable Content (cleanup) elseif (strpos($article['link'], 'campcomic.com/comic/') !== FALSE) { $imgs = $xpath->query('//img'); //doesn't get simpler than this foreach($imgs.

New Pull Request