- info_url = compat_urlparse.urljoin(url, '/medias/video/%s.json' % display_id)
- info_json = self._download_webpage(info_url, display_id)
- info = json.loads(info_json)
- return self.url_result('http://www.dailymotion.com/video/%s' % info['id'],
- ie='Dailymotion')
+ webpage = self._download_webpage(url, display_id)
+ youtube_id = self._search_regex(
+ r"window\.videoURL\s*=\s*'([0-9A-Za-z_-]{11})';",
+ webpage, 'youtube id')
+ return self.url_result(youtube_id, 'Youtube', youtube_id)