]>
jfr.im git - yt-dlp.git/blob - yt_dlp/extractor/ynet.py
5 from .common
import InfoExtractor
8 class YnetIE(InfoExtractor
):
9 _VALID_URL
= r
'https?://(?:.+?\.)?ynet\.co\.il/(?:.+?/)?0,7340,(?P<id>L(?:-[0-9]+)+),00\.html'
12 'url': 'http://hot.ynet.co.il/home/0,7340,L-11659-99244,00.html',
14 'id': 'L-11659-99244',
16 'title': 'איש לא יודע מאיפה באנו',
17 'thumbnail': r
're:^https?://.*\.jpg',
20 'url': 'http://hot.ynet.co.il/home/0,7340,L-8859-84418,00.html',
24 'title': "צפו: הנשיקה הלוהטת של תורגי' ויוליה פלוטקין",
25 'thumbnail': r
're:^https?://.*\.jpg',
30 def _real_extract(self
, url
):
31 video_id
= self
._match
_id
(url
)
32 webpage
= self
._download
_webpage
(url
, video_id
)
34 content
= urllib
.parse
.unquote_plus(self
._og
_search
_video
_url
(webpage
))
35 config
= json
.loads(self
._search
_regex
(r
'config=({.+?})$', content
, 'video config'))
36 f4m_url
= config
['clip']['url']
37 title
= self
._og
_search
_title
(webpage
)
38 m
= re
.search(r
'ynet - HOT -- (["\']+)(?P
<title
>.+?
)\
1', title)
40 title = m.group('title
')
41 formats = self._extract_f4m_formats(f4m_url, video_id)
47 'thumbnail
': self._og_search_thumbnail(webpage),