After the first if(preg_match("@.*(get_img_tags($xpath, "//div[@id='comic-1']//img", $article); } Various updates, additions elseif (strpos($article["link"], "eatthattoast.com/comic/") !== FALSE ) { $xpath = $this->get_xpath_dealie($article['link']); } /* OotS uses some kind of referer check which prevents fetch_file_contents() from retrieving the image. // Order of the Pelorinho