KoD 0.8.1
- riorganizzate le impostazioni - aggiunte descrizioni tag qualità su cb01 (presto anche sugli altri) - aggiunto il supporto alle serie di polpotv - fixato server mystream - fix Rinumerazione per episodi Nuovi
This commit is contained in:
34
servers/streamty.py
Normal file
34
servers/streamty.py
Normal file
@@ -0,0 +1,34 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# --------------------------------------------------------
|
||||
# Conector Streamty By Alfa development Group
|
||||
# --------------------------------------------------------
|
||||
|
||||
from core import httptools
|
||||
from core import scrapertools
|
||||
from lib import jsunpack
|
||||
from platformcode import logger
|
||||
|
||||
|
||||
def test_video_exists(page_url):
|
||||
logger.info("(page_url='%s')" % page_url)
|
||||
global data
|
||||
data = httptools.downloadpage(page_url).data
|
||||
if "Not Found" in data or "File was deleted" in data:
|
||||
return False, "[Streamty] El fichero no existe o ha sido borrado"
|
||||
return True, ""
|
||||
|
||||
|
||||
def get_video_url(page_url, premium=False, user="", password="", video_password=""):
|
||||
logger.info("url=" + page_url)
|
||||
video_urls = []
|
||||
|
||||
packed = scrapertools.find_single_match(data, "text/javascript'>(eval.*?)\s*</script>")
|
||||
unpacked = jsunpack.unpack(packed)
|
||||
|
||||
media_url = scrapertools.find_single_match(unpacked, 'file:"([^"]+)"')
|
||||
#media_url += "|Referer=%s" %page_url
|
||||
if "m3u8" in media_url:
|
||||
ext = "m3u8"
|
||||
video_urls.append(["%s [streamty]" % (ext), media_url])
|
||||
|
||||
return video_urls
|
||||
Reference in New Issue
Block a user