if (preg_match('/[http|https]+:\/\/(?:www\.|)rutube\.ru\/video\/embed\/([a-zA-Z0-9_\-]+)/i', $video, $matches) || preg_match('/[http|https]+:\/\/(?:www\.|)rutube\.ru\/tracks\/([a-zA-Z0-9_\-]+)(&.+)?/i', $video, $matches)) {
$video = 'http://rutube.ru/video/embed/'.$matches[1];
$image = '';
if ($xml = simplexml_load_file("http://rutube.ru/cgi-bin/xmlapi.cgi?rt_mode=movie&rt_movie_id=".$matches[1]."&utf=1")) {
$image = (string) $xml->movie->thumbnailLink;
$image = $this->getRemoteImage($image);
}
$array = array(
'video' => $video
,'image' => $image
);
}
else if (preg_match('/[http|https]+:\/\/(?:www\.|)rutube\.ru\/video\/([a-zA-Z0-9_\-]+)\//i', $video, $matches)) {
$html = $this->Curl($matches[0]);
return $this->process($html);
}
Ссылка на xml API рутуба стала такой http://rutube.ru/api/oembed/?url=htt...cf/&format=xml
Если по ней пройти то видно, что и, например thumbnailLink стала thumbnail_url. Может так и должно быть, я не знаю. Само видио грузится, а превью нет.Помогите поправить это дело.