$site = curl("http://xn--80abucjiibhv9a.xn--p1ai/news/ajax/" . $id);
preg_match("!<h2>(.*?)</h2>!si", $site, $r);
$nx = str_replace('<div class="r-article">', "", $n[0]);
$nxer = str_replace('<p>', "", $nx);
$texter = str_replace('</p>', "", $nxer);
$textx = preg_replace('/<div class="r-edited">(.*?)<\/div>/si', '', $texter);
echo preg_replace("/\s{2,}/"," ", $textx);
Код скрипта PHP: