diff options
author | remitamine <remitamine@gmail.com> | 2015-12-21 04:31:17 +0100 |
---|---|---|
committer | remitamine <remitamine@gmail.com> | 2015-12-21 04:31:17 +0100 |
commit | 7ba71e30fb9ec188d122f79a914f688928e80e91 (patch) | |
tree | 96864d5499f2024c3483a9d4970a1e6273bb90c5 /youtube_dl/extractor/makertv.py | |
parent | a8ae232fa9c24534bd9c838c793f182e6796fe4e (diff) | |
parent | 7cb09524749d4a061acc801d0a2d6ad08463e549 (diff) |
Merge branch 'bliptv' of github.com:remitamine/youtube-dl into remitamine-bliptv
Diffstat (limited to 'youtube_dl/extractor/makertv.py')
-rw-r--r-- | youtube_dl/extractor/makertv.py | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/youtube_dl/extractor/makertv.py b/youtube_dl/extractor/makertv.py new file mode 100644 index 000000000..3c34d4604 --- /dev/null +++ b/youtube_dl/extractor/makertv.py @@ -0,0 +1,32 @@ +# coding: utf-8 +from __future__ import unicode_literals + +from .common import InfoExtractor + + +class MakerTVIE(InfoExtractor): + _VALID_URL = r'https?://(?:(?:www\.)?maker\.tv/(?:[^/]+/)*video|makerplayer.com/embed/maker)/(?P<id>[a-zA-Z0-9]{12})' + _TEST = { + 'url': 'http://www.maker.tv/video/Fh3QgymL9gsc', + 'md5': 'ca237a53a8eb20b6dc5bd60564d4ab3e', + 'info_dict': { + 'id': 'Fh3QgymL9gsc', + 'ext': 'mp4', + 'title': 'Maze Runner: The Scorch Trials Official Movie Review', + 'description': 'md5:11ff3362d7ef1d679fdb649f6413975a', + 'upload_date': '20150918', + 'timestamp': 1442549540, + } + } + + def _real_extract(self, url): + video_id = self._match_id(url) + webpage = self._download_webpage(url, video_id) + jwplatform_id = self._search_regex(r'jw_?id="([^"]+)"', webpage, 'jwplatform id') + + return { + '_type': 'url_transparent', + 'id': video_id, + 'url': 'jwplatform:%s' % jwplatform_id, + 'ie_key': 'JWPlatform', + } |