From 6447353f52dc4b2b5926d3d9a3a28d3a7a242b4d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergey=20M=E2=80=A4?= Date: Thu, 23 Apr 2015 21:49:54 +0600 Subject: [PATCH] [cracked] Add support for youtube embeds --- youtube_dl/extractor/cracked.py | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/youtube_dl/extractor/cracked.py b/youtube_dl/extractor/cracked.py index e579863df..8b381dd3a 100644 --- a/youtube_dl/extractor/cracked.py +++ b/youtube_dl/extractor/cracked.py @@ -30,8 +30,15 @@ class CrackedIE(InfoExtractor): webpage = self._download_webpage(url, video_id) + youtube_url = self._search_regex( + r']+src="((?:https?:)?//www\.youtube\.com/embed/[^"]+)"', + webpage, 'youtube url', default=None) + if youtube_url: + return self.url_result(youtube_url) + video_url = self._html_search_regex( - [r'var\s+CK_vidSrc\s*=\s*"([^"]+)"', r'([^<]+)'],