2 from __future__ import unicode_literals
4 from base64 import b64decode
6 from .common import InfoExtractor
7 from ..compat import compat_urllib_parse_unquote
10 class BigflixIE(InfoExtractor):
11 _VALID_URL = r'https?://(?:www\.)?bigflix\.com/.*/(?P<id>[0-9]+)'
13 'url': 'http://www.bigflix.com/Hindi-movies/Action-movies/Singham-Returns/16537',
14 'md5': 'ec76aa9b1129e2e5b301a474e54fab74',
18 'title': 'Singham Returns',
19 'description': 'md5:3d2ba5815f14911d5cc6a501ae0cf65d',
23 def _real_extract(self, url):
24 video_id = self._match_id(url)
26 webpage = self._download_webpage(url, video_id)
28 title = self._html_search_regex(
29 r'<div[^>]+class=["\']pagetitle["\'][^>]*>(.+?)</div>',
32 video_url = b64decode(compat_urllib_parse_unquote(self._search_regex(
33 r'file=([^&]+)', webpage, 'video url')).encode('ascii')).decode('utf-8')
35 description = self._html_search_meta('description', webpage)
41 'description': description,