1 from .common
import InfoExtractor
4 class TheStarIE(InfoExtractor
):
5 _VALID_URL
= r
'https?://(?:www\.)?thestar\.com/(?:[^/]+/)*(?P<id>.+)\.html'
7 'url': 'http://www.thestar.com/life/2016/02/01/mankind-why-this-woman-started-a-men-s-skincare-line.html',
8 'md5': '2c62dd4db2027e35579fefb97a8b6554',
10 'id': '4732393888001',
12 'title': 'Mankind: Why this woman started a men\'s skin care line',
13 'description': 'Robert Cribb talks to Young Lee, the founder of Uncle Peter\'s MAN.',
14 'uploader_id': '794267642001',
15 'timestamp': 1454353482,
16 'upload_date': '20160201',
20 'skip_download': True,
23 BRIGHTCOVE_URL_TEMPLATE
= 'http://players.brightcove.net/794267642001/default_default/index.html?videoId=%s'
25 def _real_extract(self
, url
):
26 display_id
= self
._match
_id
(url
)
27 webpage
= self
._download
_webpage
(url
, display_id
)
28 brightcove_id
= self
._search
_regex
(
29 r
'mainartBrightcoveVideoId["\']?\s
*:\s
*["\']?(\d+)',
30 webpage, 'brightcove id')
31 return self.url_result(
32 self.BRIGHTCOVE_URL_TEMPLATE % brightcove_id,
33 'BrightcoveNew', brightcove_id)