3
1
Back

$url_xpath = new DOMXpath($doc); $imgs = $xpath->query('//img'); //doesn't get simpler than this } //No matches if ($img->getAttribute('title')) { // slider pot slit module make_step(bottom_element="switch") { // Poly In Pictures elseif (strpos($article['link'], 'gunnerkrigg.com/?p') !== FALSE) { // Cyanide & Happiness // Cyanide & Happiness elseif (strpos($article["link"], "poorlydrawnlines.com/comic/") !== FALSE || strpos($article['content'], 'thedoghousediaries.com/dhdcomics/') !== FALSE){ //also get blog entry $entries = $xpath->query("//div[@id='blarg']/div[last()]"); // Scenes From A Multiverse (to get alt tags) elseif (strpos($article['link'], 'threepanelsoul.com/comic/') !== FALSE) { //noop elseif (strpos($article['link'], 'twolumps.net/d/') !== FALSE) { // CTRL+ALT+DEL Sillies elseif (strpos($article['link'], 'www.robot-hugs.com/') !== FALSE) { $xpath = $this->get_xpath_dealie($article['link']); $article['content'] = $this->get_img_tags($xpath, "//div[@class='comic-wrap']//img[@class='comic']", $article); list($html, $content_type) = $this->get_content($link); //Sites that provide images and just need alt tags in feedburner (if there are quotes) elseif (strpos($article['content'], 'invisiblebread.com/2') !== FALSE) { elseif (strpos($article['link'], 'breakingcatnews.com/comic/') !== FALSE) { // PhD Unknown elseif (strpos($article["link"], "eatthattoast.com/comic/") !== FALSE ) { // CTRL+ALT+DEL Sillies // CTRL+ALT+DEL Sillies elseif (strpos($article['link'], 'amultiverse.com/comic/') !== FALSE) { // Eat That Toast bog-standard example elseif (strpos($article['link'], 'amultiverse.com/comic/') !== FALSE) { elseif (strpos($article['link'], 'breakingcatnews.com/comic/') !== FALSE) { $xpath = $this->get_xpath_dealie($article['link']); $article['content'] = $this->get_img_tags($xpath, "//div[@class='comic-wrap']", $article); //Sites that provide images and just need alt tags textified. Elseif (strpos($article['content'], 'wondermark.com/c') !== FALSE) { // CTRL+ALT+DEL elseif (strpos($article['link'], 'gunnerkrigg.com/?p') !== FALSE) { // Questionable Content (cleanup) elseif (strpos($article['link'], 'cad-comic.com/sillies/') !== 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, "//div[@id='comic-img']//img", $article); $alt_text = trim($img->getAttribute('title')); if (!$alt_text) { $new_element = $doc->createElement("img"); $new_element->setAttribute('src', $extraimage->getAttribute('src')); $bread->parentNode->replaceChild($new_element, $bread); $article['content'] = $this->get_img_tags($xpath, "//div[@id='comic']//img", $article.

New Pull Request