aboutsummaryrefslogtreecommitdiff
path: root/youtube_dl/extractor
diff options
context:
space:
mode:
authorMike Col <MikeCol@gmx.net>2014-01-21 14:12:59 +0100
committerPhilipp Hagemeister <phihag@phihag.de>2014-01-21 14:14:55 +0100
commit9d11a41fe4f1f70682640e8522565827047dbf89 (patch)
tree05d6141039693c85048e771ecadcea838e4ca6a0 /youtube_dl/extractor
parent29895011315f015d0881fd21350f301efc74f22c (diff)
[redtube] Add support for thumbnails
Signed-off-by: Philipp Hagemeister <phihag@phihag.de>
Diffstat (limited to 'youtube_dl/extractor')
-rw-r--r--youtube_dl/extractor/redtube.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/youtube_dl/extractor/redtube.py b/youtube_dl/extractor/redtube.py
index 5c4cd2068..ca2e0aae7 100644
--- a/youtube_dl/extractor/redtube.py
+++ b/youtube_dl/extractor/redtube.py
@@ -33,6 +33,10 @@ class RedTubeIE(InfoExtractor):
r'<h1 class="videoTitle[^"]*">(.+?)</h1>',
webpage, u'title')
+ video_thumbnail = self._html_search_regex(
+ r'playerInnerHTML.+?<img\s+src="(.+?)"',
+ webpage, u'thumbnail', fatal=False)
+
# No self-labeling, but they describe themselves as
# "Home of Videos Porno"
age_limit = 18
@@ -42,5 +46,6 @@ class RedTubeIE(InfoExtractor):
'url': video_url,
'ext': video_extension,
'title': video_title,
+ 'thumbnail': video_thumbnail,
'age_limit': age_limit,
}