Rimosso canale non più funzionante

This commit is contained in:
Alhaziel
2019-07-15 18:33:20 +02:00
committed by mac12m99
parent 694ff78a8f
commit 8a5357e565
2 changed files with 0 additions and 68 deletions

View File

@@ -1,10 +0,0 @@
{
"id": "streamking",
"name": "Stream King",
"language": ["ita"],
"active": true,
"adult": false,
"thumbnail": "http://streamking.cc/assets/img/logon.png",
"banner": "",
"categories": ["sport"]
}

View File

@@ -1,58 +0,0 @@
# -*- coding: utf-8 -*-
# ------------------------------------------------------------
# Canale per Stream King **** TEST ****
# Alhaziel
# ------------------------------------------------------------
import re
import urllib
from core import scrapertools, httptools
from core.item import Item
from platformcode import logger
from platformcode import config
__channel__ = "streamking"
host = config.get_channel_url(__channel__)
headers = [['Referer', host]]
def mainlist(item):
logger.info("[streamking] canali")
itemlist = []
data = httptools.downloadpage(host, headers=headers).data.replace('\n','')
patron = '<div class="tv-block">.*?<a href="([^"]+)".*?src="([^"]+)".*?title="([^"]+)"'
matches = re.compile(patron, re.DOTALL).findall(data)
for scrapedurl, scrapedthumbnail, scrapedtitle in matches:
url = host + scrapedurl
thumb = host + scrapedthumbnail
scrapedtitle = scrapertools.decodeHtmlentities(scrapedtitle)
itemlist.append(
Item(channel=item.channel,
action="findvideos",
contentTitle=scrapedtitle,
title=scrapedtitle,
fulltitle=scrapedtitle,
url=url,
thumbnail=thumb))
return itemlist
def findvideos(item):
logger.info("[streamking] findvideos")
itemlist = []
data = httptools.downloadpage(item.url, headers=headers).data.replace('\n','')
iframe = scrapertools.find_single_match(data, '<iframe src="([^"]+)"')
data = httptools.downloadpage(iframe, headers=headers).data
m3u8 = scrapertools.find_single_match(data, "file: '([^']+)'")
itemlist.append(
Item(channel=item.channel,
action="play",
title=item.title + 'Play',
url=m3u8 + '|' + urllib.urlencode(dict(headers))
))
return itemlist