3
1
Back

New DOMXpath($doc); $bread = $xpath->query("//a[contains(@href, 'bonus-panel')]")->item(0); $bread_page_url = $bread->getAttribute('href'); $xpath = $this->get_xpath_dealie($article['link']); elseif (strpos($article['link'], 'leasticoulddo.com/comic') !== FALSE) { $imgs = $xpath->query('//img'); $alt_text = trim($entry->getAttribute('alt')); $alt_text = trim($entry->getAttribute('title')); $result_html .= "Alt: " . $img->getAttribute('title') . ""; } } // Scenes From A Multiverse (to get alt tags 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, '//p[@class="Maintext"]//img[contains(@src, "joyimages")]', $article); } // CTRL+ALT+DEL elseif (strpos($article['link'], 'wondermark.com/c') !== FALSE) { $xpath = $this->get_xpath_dealie($article['link']); $article['content'] = preg_replace("@@", '', $article['content']); // Joy of Tech elseif (strpos($article['link'], 'www.timothywinchester.com/2') !== FALSE) { $xpath = $this->get_xpath_dealie($article['link']); // $article['content'] = $this->get_img_tags($xpath, "//div[@id='comic-1']//img", $article); } // Eat That Toast bog-standard example // Penny Arcade if(preg_match("@.*()@", $article['content'], $matches)){ $img = preg_replace("@height=\"\d+\"@", "", $img); $article['content'] = $this->get_img_tags($xpath, '(//div[@id="comicFrame"])', $article); } elseif (strpos($title_text, $alt_text) !== False) { if (strpos($article["content"], "bonus panel!") !== FALSE) { $xpath = new DOMDocument(); elseif (strpos($article['content'], 'wondermark.com/c') !== FALSE) { elseif (strpos($article['content'], 'www.asofterworld.com/index.php?id') !== FALSE ) { $xpath = $this->get_xpath_dealie($article['link']); $article['content'] = $this->get_img_tags($xpath, "//p[@id='comic_body']//a//img", $article); elseif (strpos($article['link'], 'www.robot-hugs.com/') !== FALSE) { elseif (strpos(strtolower($article['link']), 'giantitp.com/comics/') !== FALSE) { // Two Lumps elseif (strpos($article['link'], 'girlswithslingshots.com/comic/') !== FALSE) .

New Pull Request