2 from __future__ import unicode_literals
4 from .common import InfoExtractor
5 from ..compat import compat_urllib_parse
12 class KaraoketvIE(InfoExtractor):
13 _VALID_URL = r'http://karaoketv\.co\.il/\?container=songs&id=(?P<id>[0-9]+)'
15 'url': 'http://karaoketv.co.il/?container=songs&id=171568',
19 'title': 'אל העולם שלך - רותם כהן - שרים קריוקי',
23 def _real_extract(self, url):
24 video_id = self._match_id(url)
25 webpage = self._download_webpage(url, video_id)
27 page_video_url = self._og_search_video_url(webpage, video_id)
28 config_json = compat_urllib_parse.unquote_plus(self._search_regex(
29 r'config=(.*)', page_video_url, 'configuration'))
31 urls_info_json = self._download_json(
32 config_json, video_id, 'Downloading configuration',
33 transform_source=js_to_json)
35 url = urls_info_json['playlist'][0]['url']
39 'title': self._og_search_title(webpage),