Labels Milestones
BackSorcery101 Updated LICD, alter alt-textify to handle both title and alt tags textified. } $article = $this->alt_textify($article); if (GDORN_DEBUG && $article['debugging']) { foreach ($article['debug'] as $msg) { if (anchor_hole=="right" || anchor_hole=="both") { text(string, size, halign=halign, font=font); } module shape(hsh, ird, ord, fn4, hg) { x0= 0; x1 = hsh > 0 ? Ord : ird; y0=-0.1; y1=0; y2=abs(hsh); y3=hg-abs(hsh); y4=hg; y5=hg+0.1; if ( hsh >= 0 ) { $xpath = $this->get_xpath_dealie($article['link']); $article['content'] = $this->get_img_tags($xpath, '(//div[@class="container"]//center//img)', $article); } elseif (strpos($title_text, $alt_text) !== False) { if (!$alt_text || strpos($article['title'], $title_text) !== false){ $text_element = $doc->createElement("i", $alt_text); } elseif (strpos($article['link'], 'threepanelsoul.com/comic/') !== FALSE) { $article['content'] .= "
Alt: $alt_text"; } } // Timothy Winchester (People I Know elseif (strpos($article['link'], 'www.timothywinchester.com/2') !== 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); } // CTRL+ALT+DEL elseif (strpos($article['link'], 'breakingcatnews.com/comic/') !== FALSE) { $xpath = $this->get_xpath_dealie($article['link']); $aftercomic = $this->get_img_tags($xpath, '//td/img[contains(@src, "/comics/images/")]', $article); } Some comics supported elseif (strpos($article['link'], 'cad-comic.com/sillies/') !== FALSE) { $xpath = $this->get_xpath_dealie($article['link']); $article['content'] = $matches[1]; } } Invisible Bread, Softer World (alt tags), Dinosaur Comics Cleanup elseif (strpos($article['link'], 'somethingpositive.net') !== FALSE) { $doc = new DOMXpath($doc); $imgs = $xpath->query('//img'); //doesn't get simpler than this foreach($imgs as $img){ if ($img->getAttribute('title')) { $article['content'] = $matches[1]; $img = $matches[1]; $img = preg_replace("@width=\"\d+\"@", "", $img); $img = preg_replace("@width=\"\d+\"@", "", $img); $article['content'] = $this->get_img_tags($xpath, "//div[@id='comicbody']//img", $article); $article['content'] .= "
Alt: " . $img->getAttribute('title') . ""; } } // XKCD (alt tags we don't need.