mirror of
https://github.com/ytdl-org/youtube-dl.git
synced 2024-12-25 10:17:41 +00:00
Scrape uploader
This commit is contained in:
parent
3472227074
commit
6e109f8ad4
1 changed files with 13 additions and 0 deletions
|
@ -25,6 +25,9 @@ class XNXXIE(InfoExtractor):
|
||||||
'duration': 469,
|
'duration': 469,
|
||||||
'view_count': int,
|
'view_count': int,
|
||||||
'age_limit': 18,
|
'age_limit': 18,
|
||||||
|
'uploader': 'Glurp',
|
||||||
|
'uploader_id': 'Glurp',
|
||||||
|
'uploader_url': '/porn-maker/glurp',
|
||||||
},
|
},
|
||||||
}, {
|
}, {
|
||||||
'url': 'http://video.xnxx.com/video1135332/lida_naked_funny_actress_5_',
|
'url': 'http://video.xnxx.com/video1135332/lida_naked_funny_actress_5_',
|
||||||
|
@ -73,6 +76,13 @@ class XNXXIE(InfoExtractor):
|
||||||
r'id=["\']nb-views-number[^>]+>([\d,.]+)', webpage, 'view count',
|
r'id=["\']nb-views-number[^>]+>([\d,.]+)', webpage, 'view count',
|
||||||
default=None))
|
default=None))
|
||||||
|
|
||||||
|
uploader_data = re.findall(r'<a class="gold-plate" href="(?P<uploader_url>.+?)">(?P<uploader_name>.+?)</a>', webpage)
|
||||||
|
uploader_id = ''
|
||||||
|
uploader_url = ''
|
||||||
|
if uploader_data is not None:
|
||||||
|
uploader_id = uploader_data[0][1]
|
||||||
|
uploader_url = uploader_data[0][0]
|
||||||
|
|
||||||
return {
|
return {
|
||||||
'id': video_id,
|
'id': video_id,
|
||||||
'title': title,
|
'title': title,
|
||||||
|
@ -81,4 +91,7 @@ class XNXXIE(InfoExtractor):
|
||||||
'view_count': view_count,
|
'view_count': view_count,
|
||||||
'age_limit': 18,
|
'age_limit': 18,
|
||||||
'formats': formats,
|
'formats': formats,
|
||||||
|
'uploader': uploader_id,
|
||||||
|
'uploader_id': uploader_id,
|
||||||
|
'uploader_url': uploader_url,
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue