From 416bf97200fae95b8e66f8acf7a16c8c388621e8 Mon Sep 17 00:00:00 2001 From: yasho21 Date: Tue, 31 Mar 2020 19:56:08 -0700 Subject: [PATCH] likee_ver1.1 --- youtube_dl/extractor/extractors.py | 1 + youtube_dl/extractor/likee.py | 39 ++++++++++++++++++++++++++++++ 2 files changed, 40 insertions(+) create mode 100644 youtube_dl/extractor/likee.py diff --git a/youtube_dl/extractor/extractors.py b/youtube_dl/extractor/extractors.py index 64d1fa251..41c02eeae 100644 --- a/youtube_dl/extractor/extractors.py +++ b/youtube_dl/extractor/extractors.py @@ -570,6 +570,7 @@ from .liveleak import ( LiveLeakIE, LiveLeakEmbedIE, ) +from .likee import likeeIE from .livestream import ( LivestreamIE, LivestreamOriginalIE, diff --git a/youtube_dl/extractor/likee.py b/youtube_dl/extractor/likee.py new file mode 100644 index 000000000..9e3373d3b --- /dev/null +++ b/youtube_dl/extractor/likee.py @@ -0,0 +1,39 @@ +from __future__ import unicode_literals + +from .common import InfoExtractor + + +class likeeIE(InfoExtractor): + + + + _VALID_URL = r'(?:https?://)?(?:www\.)?likee\.com/@(?P\w+[-0-9])*/video/[0-9]+' + #print(1) + #_TESTS = { + # TODO: Implement + + #} + + def _real_extract(self, url): + video_id = self._match_id(url) + webpage = self._download_webpage( + r'http?://video\.like\.video/[A-Za-z0-9!_/=@#$%^&*(),.?:{}|<>]*', video_id + ) + + + title = "video 1" + download_url = self._html_search_regex( + + r'http?://video\.like\.video/[A-Za-z0-9!_/=@#$%^&*(),.?:{}|<>]*', + + webpage, "download_url" + ) + + + + + return { + 'id': video_id, + 'url': download_url, + 'title': title + }