]>
Raphaƫl G. Git Repositories - youtubedl/blob - youtube_dl/extractor/youjizz.py
b50f34e9bb30e47c679940ca1577ea8cc6683934
1 from __future__
import unicode_literals
3 from .common
import InfoExtractor
6 class YouJizzIE(InfoExtractor
):
7 _VALID_URL
= r
'https?://(?:\w+\.)?youjizz\.com/videos/(?:[^/#?]+)?-(?P<id>[0-9]+)\.html(?:$|[?#])'
9 'url': 'http://www.youjizz.com/videos/zeichentrick-1-2189178.html',
10 'md5': '78fc1901148284c69af12640e01c6310',
14 'title': 'Zeichentrick 1',
18 'url': 'http://www.youjizz.com/videos/-2189178.html',
19 'only_matching': True,
22 def _real_extract(self
, url
):
23 video_id
= self
._match
_id
(url
)
24 webpage
= self
._download
_webpage
(url
, video_id
)
25 # YouJizz's HTML5 player has invalid HTML
26 webpage
= webpage
.replace('"controls', '" controls')
27 age_limit
= self
._rta
_search
(webpage
)
28 video_title
= self
._html
_search
_regex
(
29 r
'<title>\s*(.*)\s*</title>', webpage
, 'title')
31 info_dict
= self
._parse
_html
5_media
_entries
(url
, webpage
, video_id
)[0]
36 'age_limit': age_limit
,