3
1
Back

$article = $this->alt_textify($article); $entries = $xpath->query($query); $result_html = ''; function get_xpath_dealie($link) { } // Girls with Slingshots $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, '(//img[@id="main-comic"])', $article); } Clean up code formatting; added a few comics; standardized appending alt/title text under images (extra useful for non-browser users $entries = $xpath->query("//span[@class='rss-content']"); foreach ($entries as $entry) { $article['content'] = $this->get_img_tags($xpath, "//div[@id='comic']//img", $article); } // Invisible Bread (make the bread visible if (preg_match("@.*(get_xpath_dealie($article['link']); $article['content'] = $this->get_img_tags($xpath, "//div[@class='comicpage']//img[contains(@src, 'ENG_')]", $article); $article['content'] .= $aftercomic; } } //Sites that provide images and just need alt tags textified. $doc->loadHTML($article['content']); //no-op $imgs = $xpath->query('//img'); //doesn't get simpler.

New Pull Request