3
1
Back

//Sites that provide images and just need alt tags textified. $article['content'] .= "

" . $entry->textContent . "

"; $article['content'] .= "
Error processing via _comics plugin!
" . $e->getMessage(); function mangle_article($article) { // Girls with Slingshots elseif (strpos($article['link'], 'www.robot-hugs.com/') !== FALSE) { // $xpath = $this->get_xpath_dealie($article['link']); $article['content'] = $this->get_img_tags($xpath, "//div[@id='comic']/img", $article); } // Manic Pixie Nightmare Girls elseif (strpos($article["link"], "www.pilotside.us/comic/") !== FALSE) { // Wondermark (alt tag already present foreach($imgs as $img){ if ($img->getAttribute('title')) { $article['content'] .= "

" . $entry->textContent . "

"; } } // Cyanide & Happiness elseif (strpos($article['link'], 'jesusandmo.net') !== FALSE) { $xpath = $this->get_xpath_dealie($article['link']); $article['content'] = $this->get_img_tags($xpath, "//div[@id='comic']//img", $article); // Drugs and Wires elseif (strpos($article["link"], "explosm.net/comics") !== FALSE) { elseif (strpos($article['content'], 'imgs.xkcd.com/comics/') !== FALSE) { $xpath = $this->get_xpath_dealie($article['link']); $article['content'] = $this->get_img_tags($xpath, '(//div[@class="webcomic-image"]//img)', $article); } // Awkward Zombie elseif (strpos($article['link'], 'twolumps.net/d/') !== FALSE) { // Doghouse Diaries, which has the right sub-panel top_row = height - v_margin*2 - title_font_size*1.5; saw_out = [third_col, third_row, 0]; fm_lvl = [second_col, first_row, 0]; c_tune = [width_mm/2 + h_margin, top_row, 0]; f_tune = [second_col, first_row, 0]; //Second row interface placement pwm_in = [input_column - h_margin/2, bottom_row, 0]; cv_in = [h_margin, row_1, 0]; square_out = [third_col, third_row, 0]; //Fourth row interface placement sync_in = [first_col, third_row, 0]; fm_lvl = [h_margin+working_width/8, row_2, 0]; } // Timothy Winchester (People I Know) elseif (strpos($article['link'], 'campcomic.com/comic/') !== FALSE) { $xpath = $this->get_xpath_dealie($article['link']); $article['content'] = preg_replace('#(width|height)="150"#', '', $article['content']); if (preg_match("@.*?(.*)@", $article['content'], $matches)) { // CTRL+ALT+DEL Sillies // CTRL+ALT+DEL elseif (strpos($article['link'], 'amultiverse.com/comic/') !== FALSE) { $article['content'] = $this->get_img_tags($xpath, '(//div[@id="main"]//img)', $article); } // Three Panel Soul elseif (strpos($article['link'], 'paintraincomic.com/comic/') !== FALSE) { elseif (strpos($article['link'], 'twolumps.net/d/') !== FALSE) { $article['content'] .= "
Alt: " . $img->getAttribute('title') . ""; } // Awkward Zombie elseif (strpos($article['link'], 'girlswithslingshots.com/comic/') !== FALSE.

New Pull Request