1 from __future__ import unicode_literals
3 from .common import InfoExtractor
4 from .internetvideoarchive import InternetVideoArchiveIE
7 class RottenTomatoesIE(InfoExtractor):
8 _VALID_URL = r'https?://(?:www\.)?rottentomatoes\.com/m/[^/]+/trailers/(?P<id>\d+)'
11 'url': 'http://www.rottentomatoes.com/m/toy_story_3/trailers/11028566/',
15 'title': 'Toy Story 3',
16 'description': 'From the creators of the beloved TOY STORY films, comes a story that will reunite the gang in a whole new way.',
17 'thumbnail': 're:^https?://.*\.jpg$',
21 def _real_extract(self, url):
22 video_id = self._match_id(url)
23 webpage = self._download_webpage(url, video_id)
24 iva_id = self._search_regex(r'publishedid=(\d+)', webpage, 'internet video archive id')
27 '_type': 'url_transparent',
28 'url': 'http://video.internetvideoarchive.net/player/6/configuration.ashx?domain=www.videodetective.com&customerid=69249&playerid=641&publishedid=' + iva_id,
29 'ie_key': InternetVideoArchiveIE.ie_key(),
31 'title': self._og_search_title(webpage),