예제 #1
0
    def sources(self, url, hostDict, hostprDict):
        try:
            sources = []
            if url == None: return sources
            html = client.request(url)

            source = re.compile('<iframe src="(.+?)"',re.DOTALL).findall(html)[0]
            if 'consistent.stream' in source:
                html = client.request(source)
                page = re.compile(""":title=["'](.+?)["']\>""").findall(html)[0]
                decode = client.replaceEscapeCodes(page)
                links = re.compile('"sources.+?"(http.+?)"',re.DOTALL).findall(decode)
                for link in links:
                    link = link.replace('\\','')
                    if '1080' in link:
                        quality='1080p'
                    elif '720' in link:
                        quality = '720p'
                    else:
                        quality = 'DVD'
                    host = link.split('//')[1].replace('www.','')
                    host = host.split('/')[0].split('.')[0].title()
                    sources.append({'source': host, 'quality': quality, 'language': 'en', 'url': link, 'direct': False, 'debridonly': False})
            return sources
        except:
            failure = traceback.format_exc()
            log_utils.log('VexMovies - Exception: \n' + str(failure))
            return sources
예제 #2
0
    def sources(self, url, hostDict, hostprDict):
        try:
            sources = []
            if url == None: return sources
            html = client.request(url)

            source = re.compile('<iframe src="(.+?)"',re.DOTALL).findall(html)[0]
            if 'consistent.stream' in source:
                html = client.request(source)
                page = re.compile(""":title=["'](.+?)["']\>""").findall(html)[0]
                decode = client.replaceEscapeCodes(page)
                links = re.compile('"sources.+?"(http.+?)"',re.DOTALL).findall(decode)
                for link in links:
                    link = link.replace('\\','')
                    if '1080' in link:
                        quality='1080p'
                    elif '720' in link:
                        quality = '720p'
                    else:
                        quality = 'DVD'
                    host = link.split('//')[1].replace('www.','')
                    host = host.split('/')[0].split('.')[0].title()
                    sources.append({'source': host, 'quality': quality, 'language': 'en', 'url': link, 'direct': False, 'debridonly': False})
            return sources
        except:
            return sources