', '', $string); return $string; } function Rue89ExtractContent($url) { $html2 = file_get_html($url); //$text = $html2->find('div[class=text]', 0)->innertext; foreach($html2->find('img') as $image) { $image->src = $image->getAttribute('data-src'); } $text = $html2->find('div.content', 0)->innertext; $text = str_replace('href="/', 'href="http://rue89.nouvelobs.com/', $text); $text = str_replace('src="/', 'src="http://rue89.nouvelobs.com/', $text); $text = preg_replace('@@si', '', $text); $text = strip_tags($text, '