]>
Raphaël G. Git Repositories - youtubedl/blob - youtube_dl/extractor/bild.py
1a0184861d20d7674badc042bfc44fbda6c9718b
2 from __future__
import unicode_literals
4 from .common
import InfoExtractor
11 class BildIE(InfoExtractor
):
12 _VALID_URL
= r
'https?://(?:www\.)?bild\.de/(?:[^/]+/)+(?P<display_id>[^/]+)-(?P<id>\d+)(?:,auto=true)?\.bild\.html'
15 'url': 'http://www.bild.de/video/clip/apple-ipad-air/das-koennen-die-neuen-ipads-38184146.bild.html',
16 'md5': 'dd495cbd99f2413502a1713a1156ac8a',
20 'title': 'Das können die neuen iPads',
21 'description': 'md5:a4058c4fa2a804ab59c00d7244bbf62f',
22 'thumbnail': 're:^https?://.*\.jpg$',
27 def _real_extract(self
, url
):
28 video_id
= self
._match
_id
(url
)
30 video_data
= self
._download
_json
(
31 url
.split('.bild.html')[0] + ',view=json.bild.html', video_id
)
35 'title': unescapeHTML(video_data
['title']).strip(),
36 'description': unescapeHTML(video_data
.get('description')),
37 'url': video_data
['clipList'][0]['srces'][0]['src'],
38 'thumbnail': video_data
.get('poster'),
39 'duration': int_or_none(video_data
.get('durationSec')),