]>
Raphaƫl G. Git Repositories - youtubedl/blob - youtube_dl/extractor/extremetube.py
b4fd9334aeb7f3dfc3f45ce2da67e5236d5d4018
1 from __future__
import unicode_literals
3 from ..utils
import str_to_int
4 from .keezmovies
import KeezMoviesIE
7 class ExtremeTubeIE(KeezMoviesIE
):
8 _VALID_URL
= r
'https?://(?:www\.)?extremetube\.com/(?:[^/]+/)?video/(?:(?P<display_id>[^/]+)-)(?P<id>\d+)'
10 'url': 'http://www.extremetube.com/video/music-video-14-british-euro-brit-european-cumshots-swallow-652431',
11 'md5': '1fb9228f5e3332ec8c057d6ac36f33e0',
14 'display_id': 'music-video-14-british-euro-brit-european-cumshots-swallow',
16 'title': 'Music Video 14 british euro brit european cumshots swallow',
17 'uploader': 'unknown',
22 'url': 'http://www.extremetube.com/gay/video/abcde-1234',
23 'only_matching': True,
25 'url': 'http://www.extremetube.com/video/latina-slut-fucked-by-fat-black-dick',
26 'only_matching': True,
28 'url': 'http://www.extremetube.com/video/652431',
29 'only_matching': True,
32 def _real_extract(self
, url
):
33 webpage
, info
= self
._extract
_info
(url
)
36 info
['title'] = self
._search
_regex
(
37 r
'<h1[^>]+title="([^"]+)"[^>]*>', webpage
, 'title')
39 uploader
= self
._html
_search
_regex
(
40 r
'Uploaded by:\s*</strong>\s*(.+?)\s*</div>',
41 webpage
, 'uploader', fatal
=False)
42 view_count
= str_to_int(self
._search
_regex
(
43 r
'Views:\s*</strong>\s*<span>([\d,\.]+)</span>',
44 webpage
, 'view count', fatal
=False))
48 'view_count': view_count
,