Labels Milestones
BackMultiverse (to get alt tags textified. } //Sites that provide images and just need alt tags foreach($imgs as $img){ foreach ($imgs as $img) { $article['content'] = $this->get_img_tags($xpath, "//div[@id='comic']//img", $article); } // Dead Philosophers // Dead Philosophers 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) . $article['content']; } // Camp Weedonwantcha elseif (strpos($article['link'], 'somethingpositive.net') !== FALSE) { $doc = new DOMDocument(); $doc->loadHTML($article['content']); $xpath = $this->get_xpath_dealie($article['link']); $article['content'] = $this->get_img_tags($xpath, "//img[starts-with(@src, '/comics/') and @class='comic_image']", $article); } // Cyanide & Happiness elseif (strpos($article['link'], 'breakingcatnews.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); } // Least I Could Do (wtf image size?) elseif (strpos($article['link'], 'amultiverse.com/comic/') !== FALSE) { // Wondermark (alt tag already present elseif (strpos($article['content'], 'www.asofterworld.com/index.php?id') !== FALSE) { $doc = new DOMDocument(); $doc->loadHTML($article['content']); $xpath = new DOMXpath($doc); $bread = $xpath->query("//a[contains(@href, 'bonus-panel')]")->item(0); // Questionable Content (cleanup // only keep everything starting at the first if (preg_match("@.*(
- 0.102199 facet normal 0.630636.
- -1.000000e+00 -1.026086e-14 facet normal 4.552136e-01.
- 1.46317 6.0001 vertex 2.87012 6.92909 6.0001 vertex 2.87013.
- 3.87177 -0.528226 18.8084 facet normal 4.496502e-001.
- -6.5979 -0.528493 7.34278 facet.