]>
Raphaël G. Git Repositories - youtubedl/blob - youtube_dl/extractor/restudy.py
2 from __future__
import unicode_literals
4 from .common
import InfoExtractor
7 class RestudyIE(InfoExtractor
):
8 _VALID_URL
= r
'https?://(?:(?:www|portal)\.)?restudy\.dk/video/[^/]+/id/(?P<id>[0-9]+)'
10 'url': 'https://www.restudy.dk/video/play/id/1637',
14 'title': 'Leiden-frosteffekt',
15 'description': 'Denne video er et eksperiment med flydende kvælstof.',
19 'skip_download': True,
22 'url': 'https://portal.restudy.dk/video/leiden-frosteffekt/id/1637',
23 'only_matching': True,
26 def _real_extract(self
, url
):
27 video_id
= self
._match
_id
(url
)
29 webpage
= self
._download
_webpage
(url
, video_id
)
31 title
= self
._og
_search
_title
(webpage
).strip()
32 description
= self
._og
_search
_description
(webpage
).strip()
34 formats
= self
._extract
_smil
_formats
(
35 'https://cdn.portal.restudy.dk/dynamic/themes/front/awsmedia/SmilDirectory/video_%s.xml' % video_id
,
37 self
._sort
_formats
(formats
)
42 'description': description
,