add support.py, new channel, casacinema new url and some cleanup
This commit is contained in:
@@ -8,7 +8,7 @@ import re
|
||||
import urlparse
|
||||
|
||||
from channels import autoplay
|
||||
from channels import filtertools
|
||||
from channels import filtertools, support
|
||||
from core import scrapertools, servertools, httptools, tmdb
|
||||
from core.item import Item
|
||||
from platformcode import logger, config
|
||||
@@ -18,7 +18,7 @@ host = "https://altadefinizione.center" ### <- cambio Host da .fm a .center
|
||||
IDIOMAS = {'Italiano': 'IT'}
|
||||
list_language = IDIOMAS.values()
|
||||
list_servers = ['openload', 'streamango', "vidoza", "thevideo", "okru", 'youtube']
|
||||
list_quality = ['default']
|
||||
list_quality = ['1080p']
|
||||
|
||||
__comprueba_enlaces__ = config.get_setting('comprueba_enlaces', 'altadefinizioneclick')
|
||||
__comprueba_enlaces_num__ = config.get_setting('comprueba_enlaces_num', 'altadefinizioneclick')
|
||||
@@ -221,49 +221,7 @@ def findvideos(item):
|
||||
|
||||
itemlist = []
|
||||
|
||||
# Carica la pagina
|
||||
data = httptools.downloadpage(item.url, headers=headers).data.replace('\n', '')
|
||||
patron = r'<iframe id="[^"]+" width="[^"]+" height="[^"]+" src="([^"]+)"[^>]+><\/iframe>'
|
||||
url = scrapertools.find_single_match(data, patron).replace("?alta", "")
|
||||
url = url.replace("&download=1", "")
|
||||
|
||||
if 'hdpass' in url:
|
||||
data = httptools.downloadpage(url, headers=headers).data
|
||||
|
||||
start = data.find('<div class="row mobileRes">')
|
||||
end = data.find('<div id="playerFront">', start)
|
||||
data = data[start:end]
|
||||
|
||||
patron_res = '<div class="row mobileRes">(.*?)</div>'
|
||||
patron_mir = '<div class="row mobileMirrs">(.*?)</div>'
|
||||
patron_media = r'<input type="hidden" name="urlEmbed" data-mirror="([^"]+)" id="urlEmbed" value="([^"]+)"\s*/>'
|
||||
|
||||
res = scrapertools.find_single_match(data, patron_res)
|
||||
|
||||
urls = []
|
||||
for res_url, res_video in scrapertools.find_multiple_matches(res, '<option.*?value="([^"]+?)">([^<]+?)</option>'):
|
||||
|
||||
data = httptools.downloadpage(urlparse.urljoin(url, res_url), headers=headers).data.replace('\n', '')
|
||||
|
||||
mir = scrapertools.find_single_match(data, patron_mir)
|
||||
|
||||
for mir_url in scrapertools.find_multiple_matches(mir, '<option.*?value="([^"]+?)">[^<]+?</value>'):
|
||||
|
||||
data = httptools.downloadpage(urlparse.urljoin(url, mir_url), headers=headers).data.replace('\n', '')
|
||||
|
||||
for media_label, media_url in re.compile(patron_media).findall(data):
|
||||
urls.append(url_decode(media_url))
|
||||
|
||||
itemlist = servertools.find_video_items(data='\n'.join(urls))
|
||||
for videoitem in itemlist:
|
||||
videoitem.title = item.title + videoitem.title
|
||||
videoitem.fulltitle = item.fulltitle
|
||||
videoitem.thumbnail = item.thumbnail
|
||||
videoitem.show = item.show
|
||||
videoitem.plot = item.plot
|
||||
videoitem.channel = item.channel
|
||||
videoitem.contentType = item.contentType
|
||||
videoitem.language = IDIOMAS['Italiano']
|
||||
itemlist = support.hdpass_get_servers(item)
|
||||
|
||||
# Requerido para Filtrar enlaces
|
||||
|
||||
@@ -285,26 +243,3 @@ def findvideos(item):
|
||||
action="add_pelicula_to_library", extra="findvideos", contentTitle=item.contentTitle))
|
||||
|
||||
return itemlist
|
||||
|
||||
|
||||
def url_decode(url_enc):
|
||||
lenght = len(url_enc)
|
||||
if lenght % 2 == 0:
|
||||
len2 = lenght / 2
|
||||
first = url_enc[0:len2]
|
||||
last = url_enc[len2:lenght]
|
||||
url_enc = last + first
|
||||
reverse = url_enc[::-1]
|
||||
return base64.b64decode(reverse)
|
||||
|
||||
last_car = url_enc[lenght - 1]
|
||||
url_enc[lenght - 1] = ' '
|
||||
url_enc = url_enc.strip()
|
||||
len1 = len(url_enc)
|
||||
len2 = len1 / 2
|
||||
first = url_enc[0:len2]
|
||||
last = url_enc[len2:len1]
|
||||
url_enc = last + first
|
||||
reverse = url_enc[::-1]
|
||||
reverse = reverse + last_car
|
||||
return base64.b64decode(reverse)
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
import re
|
||||
|
||||
from channels import autoplay
|
||||
from channels import filtertools
|
||||
from channels import filtertools, support
|
||||
from core import servertools, httptools, scrapertools, tmdb
|
||||
from platformcode import logger, config
|
||||
from core.item import Item
|
||||
@@ -164,7 +164,7 @@ def episodios(item):
|
||||
contentType=item.contentType,
|
||||
title="Episodio: 1",
|
||||
text_color="azure",
|
||||
fulltitle="%s %s %s " % (color(item.title, "deepskyblue"), color("|", "azure"), color("1", "orange")),
|
||||
fulltitle="%s %s %s " % (support.color(item.title, "deepskyblue"), support.color("|", "azure"), support.color("1", "orange")),
|
||||
url=item.url,
|
||||
thumbnail=item.thumbnail,
|
||||
folder=True))
|
||||
@@ -178,7 +178,7 @@ def episodios(item):
|
||||
contentType=item.contentType,
|
||||
title="Episodio: %s" % scrapednumber,
|
||||
text_color="azure",
|
||||
fulltitle="%s %s %s " % (color(item.title, "deepskyblue"), color("|", "azure"), color(scrapednumber, "orange")),
|
||||
fulltitle="%s %s %s " % (support.color(item.title, "deepskyblue"), support.color("|", "azure"), color(scrapednumber, "orange")),
|
||||
url=scrapedurl,
|
||||
thumbnail=item.thumbnail,
|
||||
folder=True))
|
||||
@@ -202,7 +202,7 @@ def findvideos(item):
|
||||
|
||||
for videoitem in itemlist:
|
||||
server = re.sub(r'[-\[\]\s]+', '', videoitem.title)
|
||||
videoitem.title = "".join(["[%s] " % color(server.capitalize(), 'orange'), item.title])
|
||||
videoitem.title = "".join(["[%s] " % support.color(server.capitalize(), 'orange'), item.title])
|
||||
videoitem.fulltitle = item.fulltitle
|
||||
videoitem.show = item.show
|
||||
videoitem.thumbnail = item.thumbnail
|
||||
@@ -219,6 +219,3 @@ def findvideos(item):
|
||||
autoplay.start(itemlist, item)
|
||||
|
||||
return itemlist
|
||||
|
||||
def color(text, color):
|
||||
return "[COLOR %s]%s[/COLOR]" % (color, text)
|
||||
|
||||
@@ -10,6 +10,7 @@ import re, urllib, urlparse
|
||||
from core import servertools, httptools, scrapertools, tmdb
|
||||
from platformcode import logger, config
|
||||
from core.item import Item
|
||||
from channels import support
|
||||
|
||||
|
||||
|
||||
@@ -22,27 +23,27 @@ def mainlist(item):
|
||||
logger.info()
|
||||
itemlist = [Item(channel=item.channel,
|
||||
action="lista_anime_completa",
|
||||
title=color("Lista Anime", "azure"),
|
||||
title=support.color("Lista Anime", "azure"),
|
||||
url="%s/lista-anime/" % host,
|
||||
thumbnail="http://orig03.deviantart.net/6889/f/2014/079/7/b/movies_and_popcorn_folder_icon_by_matheusgrilo-d7ay4tw.png"),
|
||||
Item(channel=item.channel,
|
||||
action="ultimiep",
|
||||
title=color("Ultimi Episodi", "azure"),
|
||||
title=support.color("Ultimi Episodi", "azure"),
|
||||
url="%s/category/ultimi-episodi/" % host,
|
||||
thumbnail="http://orig03.deviantart.net/6889/f/2014/079/7/b/movies_and_popcorn_folder_icon_by_matheusgrilo-d7ay4tw.png"),
|
||||
Item(channel=item.channel,
|
||||
action="lista_anime",
|
||||
title=color("Anime in corso", "azure"),
|
||||
title=support.color("Anime in corso", "azure"),
|
||||
url="%s/category/anime-in-corso/" % host,
|
||||
thumbnail="http://orig03.deviantart.net/6889/f/2014/079/7/b/movies_and_popcorn_folder_icon_by_matheusgrilo-d7ay4tw.png"),
|
||||
Item(channel=item.channel,
|
||||
action="categorie",
|
||||
title=color("Categorie", "azure"),
|
||||
title=support.color("Categorie", "azure"),
|
||||
url="%s/generi/" % host,
|
||||
thumbnail="http://orig03.deviantart.net/6889/f/2014/079/7/b/movies_and_popcorn_folder_icon_by_matheusgrilo-d7ay4tw.png"),
|
||||
Item(channel=item.channel,
|
||||
action="search",
|
||||
title=color("Cerca anime ...", "yellow"),
|
||||
title=support.color("Cerca anime ...", "yellow"),
|
||||
extra="anime",
|
||||
thumbnail="http://dc467.4shared.com/img/fEbJqOum/s7/13feaf0c8c0/Search")
|
||||
]
|
||||
@@ -136,7 +137,7 @@ def ultimiep(item):
|
||||
eptype += ":? " + epnumber
|
||||
|
||||
extra = "<tr>\s*<td[^>]+><strong>(?:[^>]+>|)%s(?:[^>]+>[^>]+>|[^<]*|[^>]+>)</strong>" % eptype
|
||||
itm.title = color(title, 'azure').strip()
|
||||
itm.title = support.color(title, 'azure').strip()
|
||||
itm.action = "findvideos"
|
||||
itm.url = url
|
||||
itm.fulltitle = cleantitle
|
||||
@@ -179,7 +180,7 @@ def lista_anime(item, nextpage=True, show_lang=True):
|
||||
Item(channel=item.channel,
|
||||
action="episodi",
|
||||
contentType="tvshow" if 'oav' not in scrapedtitle.lower() else "movie",
|
||||
title=color(scrapedtitle.replace(lang, "(%s)" % color(lang, "red") if show_lang else "").strip(), 'azure'),
|
||||
title=color(scrapedtitle.replace(lang, "(%s)" % support.color(lang, "red") if show_lang else "").strip(), 'azure'),
|
||||
fulltitle=cleantitle,
|
||||
url=scrapedurl,
|
||||
show=cleantitle,
|
||||
@@ -231,7 +232,7 @@ def lista_anime_completa(item):
|
||||
Item(channel=item.channel,
|
||||
action="episodi",
|
||||
contentType="tvshow" if 'oav' not in scrapedtitle.lower() else "movie",
|
||||
title=color(scrapedtitle, 'azure'),
|
||||
title=support.color(scrapedtitle, 'azure'),
|
||||
fulltitle=cleantitle,
|
||||
show=cleantitle,
|
||||
url=scrapedurl,
|
||||
@@ -333,7 +334,7 @@ def findvideos(item):
|
||||
Item(channel=item.channel,
|
||||
action="play",
|
||||
text_color="azure",
|
||||
title="[%s] %s" % (color("Diretto", "orange"), item.title),
|
||||
title="[%s] %s" % (support.color("Diretto", "orange"), item.title),
|
||||
fulltitle=item.fulltitle,
|
||||
url=url,
|
||||
thumbnail=item.thumbnail,
|
||||
@@ -341,11 +342,3 @@ def findvideos(item):
|
||||
plot=item.plot))
|
||||
|
||||
return itemlist
|
||||
|
||||
# ================================================================================================================
|
||||
|
||||
# ----------------------------------------------------------------------------------------------------------------
|
||||
def color(text, color):
|
||||
return "[COLOR %s]%s[/COLOR]" % (color, text)
|
||||
|
||||
# ================================================================================================================
|
||||
|
||||
@@ -1,17 +1,17 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# ------------------------------------------------------------
|
||||
# Ringraziamo Icarus crew
|
||||
# Kodi on Demand - Kodi Addon
|
||||
# Canale per casacinema
|
||||
# ------------------------------------------------------------
|
||||
import re, urlparse
|
||||
|
||||
from core import scrapertools, scrapertoolsV2, httptools, servertools, tmdb
|
||||
from channels import autoplay, filtertools
|
||||
from channels import autoplay, filtertools, support
|
||||
from core.item import Item
|
||||
from platformcode import logger, config
|
||||
|
||||
|
||||
host = 'https://www.casacinema.news' ### <- Camio Host da .video a .news -> Continua. riga 164
|
||||
host = 'https://www.casacinema.site'
|
||||
|
||||
IDIOMAS = {'Italiano': 'IT'}
|
||||
list_language = IDIOMAS.values()
|
||||
@@ -341,7 +341,7 @@ def findvideos(item):
|
||||
itemlist = servertools.find_video_items(data=data)
|
||||
for videoitem in itemlist:
|
||||
server = re.sub(r'[-\[\]\s]+', '', videoitem.title).capitalize()
|
||||
videoitem.title = "".join(["[%s] " % color(server, 'orange'), item.title])
|
||||
videoitem.title = "".join(["[%s] " % support.color(server, 'orange'), item.title])
|
||||
videoitem.fulltitle = item.fulltitle
|
||||
videoitem.thumbnail = item.thumbnail
|
||||
videoitem.show = item.show
|
||||
@@ -371,5 +371,3 @@ def findvideos(item):
|
||||
|
||||
return itemlist
|
||||
|
||||
def color(text, color):
|
||||
return "[COLOR " + color + "]" + text + "[/COLOR]"
|
||||
|
||||
36
plugin.video.alfa/channels/casacinemaInfo.json
Normal file
36
plugin.video.alfa/channels/casacinemaInfo.json
Normal file
@@ -0,0 +1,36 @@
|
||||
{
|
||||
"id": "casacinemaInfo",
|
||||
"name": "La casa del cinema",
|
||||
"language": ["ita"],
|
||||
"active": true,
|
||||
"adult": false,
|
||||
"thumbnail": "",
|
||||
"banner": "",
|
||||
"categories": ["movie"],
|
||||
"settings": [
|
||||
{
|
||||
"id": "include_in_global_search",
|
||||
"type": "bool",
|
||||
"label": "Includi ricerca globale",
|
||||
"default": true,
|
||||
"enabled": true,
|
||||
"visible": true
|
||||
},
|
||||
{
|
||||
"id": "include_in_newest_peliculas",
|
||||
"type": "bool",
|
||||
"label": "Includi in Novità - Film",
|
||||
"default": true,
|
||||
"enabled": true,
|
||||
"visible": true
|
||||
},
|
||||
{
|
||||
"id": "include_in_newest_italiano",
|
||||
"type": "bool",
|
||||
"label": "Includi in Novità - Italiano",
|
||||
"default": true,
|
||||
"enabled": true,
|
||||
"visible": true
|
||||
}
|
||||
]
|
||||
}
|
||||
154
plugin.video.alfa/channels/casacinemaInfo.py
Normal file
154
plugin.video.alfa/channels/casacinemaInfo.py
Normal file
@@ -0,0 +1,154 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# ------------------------------------------------------------
|
||||
# Ringraziamo Icarus crew
|
||||
# Canale per casacinema
|
||||
# ------------------------------------------------------------
|
||||
import re, urlparse, base64
|
||||
|
||||
from core import scrapertoolsV2, httptools, servertools, tmdb
|
||||
from channels import autoplay, support
|
||||
from core.item import Item
|
||||
from platformcode import logger, config
|
||||
|
||||
|
||||
host = 'https://casacinema.info'
|
||||
|
||||
IDIOMAS = {'Italiano': 'IT'}
|
||||
list_language = IDIOMAS.values()
|
||||
list_servers = ['openload', 'wstream', 'speedvideo']
|
||||
list_quality = ['1080p', '720', '480p', '360p']
|
||||
|
||||
__comprueba_enlaces__ = config.get_setting('comprueba_enlaces', 'casacinema')
|
||||
__comprueba_enlaces_num__ = config.get_setting('comprueba_enlaces_num', 'casacinema')
|
||||
|
||||
|
||||
def mainlist(item):
|
||||
logger.info("alfa.casacinema mainlist")
|
||||
|
||||
autoplay.init(item.channel, list_servers, list_quality)
|
||||
|
||||
itemlist = [Item(channel=item.channel,
|
||||
title="Film",
|
||||
action="peliculas",
|
||||
extra="movie",
|
||||
url=host,
|
||||
thumbnail="http://orig03.deviantart.net/6889/f/2014/079/7/b/movies_and_popcorn_folder_icon_by_matheusgrilo-d7ay4tw.png"),
|
||||
Item(channel=item.channel,
|
||||
title="In sala",
|
||||
action="peliculas",
|
||||
extra="movie",
|
||||
url="%s/category/in-sala/" % host,
|
||||
thumbnail="http://jcrent.com/apple%20tv%20final/HD.png"),
|
||||
Item(channel=item.channel,
|
||||
title="Novità",
|
||||
action="peliculas",
|
||||
extra="movie",
|
||||
url="%s/category/nuove-uscite/" % host,
|
||||
thumbnail="http://orig03.deviantart.net/6889/f/2014/079/7/b/movies_and_popcorn_folder_icon_by_matheusgrilo-d7ay4tw.png"),
|
||||
Item(channel=item.channel,
|
||||
title="Sub - Ita",
|
||||
action="peliculas",
|
||||
extra="movie",
|
||||
url="%s/category/sub-ita/" % host,
|
||||
thumbnail="http://i.imgur.com/qUENzxl.png"),
|
||||
Item(channel=item.channel,
|
||||
title="[COLOR yellow]Cerca...[/COLOR]",
|
||||
action="search",
|
||||
extra="movie",
|
||||
thumbnail="http://dc467.4shared.com/img/fEbJqOum/s7/13feaf0c8c0/Search")]
|
||||
|
||||
|
||||
autoplay.show_option(item.channel, itemlist)
|
||||
|
||||
return itemlist
|
||||
|
||||
|
||||
def search(item, texto):
|
||||
logger.info("[casacinemaInfo.py] " + item.url + " search " + texto)
|
||||
|
||||
item.url = host + "?s=" + texto
|
||||
data = httptools.downloadpage(item.url).data
|
||||
|
||||
itemlist = []
|
||||
|
||||
patron = '<li class="col-md-12 itemlist">.*?<a href="([^"]+)" title="([^"]+)".*?<img src="([^"]+)".*?Film dell\\\'anno: ([0-9]{4}).*?<p class="text-list">([^<>]+)</p>'
|
||||
matches = scrapertoolsV2.find_multiple_matches(data, patron)
|
||||
for scrapedurl, scrapedtitle, scrapedthumbnail, scrapedyear, scrapedplot in matches:
|
||||
title = scrapertoolsV2.decodeHtmlentities(scrapedtitle)
|
||||
cleantitle = title.replace('[Sub-ITA]', '').strip()
|
||||
|
||||
infoLabels = {"plot": scrapertoolsV2.decodeHtmlentities(scrapedplot), "year": scrapedyear}
|
||||
|
||||
itemlist.append(
|
||||
Item(channel=item.channel,
|
||||
action="findvideos",
|
||||
contentType="movie",
|
||||
title=title,
|
||||
url=scrapedurl,
|
||||
thumbnail=scrapedthumbnail,
|
||||
infoLabels=infoLabels,
|
||||
fulltitle=cleantitle))
|
||||
|
||||
tmdb.set_infoLabels_itemlist(itemlist, seekTmdb=True)
|
||||
|
||||
return itemlist
|
||||
|
||||
|
||||
def peliculas(item):
|
||||
logger.info("[casacinemaInfo.py] peliculas")
|
||||
|
||||
itemlist = []
|
||||
|
||||
# Carica la pagina
|
||||
data = httptools.downloadpage(item.url).data
|
||||
|
||||
# Estrae i contenuti
|
||||
|
||||
patron = '<div class="col-mt-5 postsh">[^<>]+<div class="poster-media-card">[^<>]+<a href="([^"]+)" title="([^"]+)".*?<img src="([^"]+)"'
|
||||
|
||||
matches = scrapertoolsV2.find_multiple_matches(data, patron)
|
||||
|
||||
for scrapedurl, scrapedtitle, scrapedthumbnail in matches:
|
||||
title = scrapertoolsV2.decodeHtmlentities(scrapedtitle)
|
||||
cleantitle = title.replace('[Sub-ITA]', '').strip()
|
||||
|
||||
itemlist.append(
|
||||
Item(channel=item.channel,
|
||||
action="findvideos",
|
||||
contentType="movie",
|
||||
title=title,
|
||||
url=scrapedurl,
|
||||
thumbnail=scrapedthumbnail,
|
||||
fulltitle=cleantitle))
|
||||
|
||||
tmdb.set_infoLabels_itemlist(itemlist, seekTmdb=True)
|
||||
|
||||
## Paginación
|
||||
next_page = scrapertoolsV2.find_single_match(data, '<a href="([^"]+)"><i class="glyphicon glyphicon-chevron-right"') ### <- Regex rimosso spazio - precedente <li><a href="([^"]+)" >Pagina -> Continua. riga 221
|
||||
|
||||
if next_page != "":
|
||||
itemlist.append(
|
||||
Item(channel=item.channel,
|
||||
action="peliculas",
|
||||
title="[COLOR lightgreen]" + config.get_localized_string(30992) + "[/COLOR]",
|
||||
url=next_page,
|
||||
extra=item.extra,
|
||||
thumbnail="http://2.bp.blogspot.com/-fE9tzwmjaeQ/UcM2apxDtjI/AAAAAAAAeeg/WKSGM2TADLM/s1600/pager+old.png"))
|
||||
|
||||
return itemlist
|
||||
|
||||
|
||||
def findvideos(item):
|
||||
logger.info("[casacinemaInfo.py] findvideos")
|
||||
|
||||
itemlist = support.hdpass_get_servers(item)
|
||||
|
||||
# Requerido para Filtrar enlaces
|
||||
|
||||
if __comprueba_enlaces__:
|
||||
itemlist = servertools.check_list_links(itemlist, __comprueba_enlaces_num__)
|
||||
|
||||
# Requerido para AutoPlay
|
||||
|
||||
autoplay.start(itemlist, item)
|
||||
return itemlist
|
||||
@@ -10,6 +10,7 @@ from platformcode import logger, config
|
||||
from core import httptools, scrapertools, servertools
|
||||
from core.item import Item
|
||||
from core import tmdb
|
||||
from channels import support
|
||||
|
||||
host = "https://www.cineblog01.cloud"
|
||||
|
||||
@@ -20,21 +21,21 @@ def mainlist(item):
|
||||
logger.info()
|
||||
itemlist = [Item(channel=item.channel,
|
||||
action="peliculas",
|
||||
title=color("Nuovi film", "azure"),
|
||||
title=support.color("Nuovi film", "azure"),
|
||||
url="%s/new-film-streaming/" % host,
|
||||
thumbnail="http://orig03.deviantart.net/6889/f/2014/079/7/b/movies_and_popcorn_folder_icon_by_matheusgrilo-d7ay4tw.png"),
|
||||
Item(channel=item.channel,
|
||||
action="categorie",
|
||||
title=color("Categorie", "azure"),
|
||||
title=support.color("Categorie", "azure"),
|
||||
url=host,
|
||||
thumbnail="http://orig03.deviantart.net/6889/f/2014/079/7/b/movies_and_popcorn_folder_icon_by_matheusgrilo-d7ay4tw.png"),
|
||||
Item(channel=item.channel,
|
||||
action="filmperanno",
|
||||
title=color("Film per anno", "azure"),
|
||||
title=support.color("Film per anno", "azure"),
|
||||
url=host,
|
||||
thumbnail="http://orig03.deviantart.net/6889/f/2014/079/7/b/movies_and_popcorn_folder_icon_by_matheusgrilo-d7ay4tw.png"),
|
||||
Item(channel=item.channel,
|
||||
title=color("Cerca ..." , "yellow"),
|
||||
title=support.color("Cerca ..." , "yellow"),
|
||||
action="search",
|
||||
extra="movie",
|
||||
thumbnail="http://dc467.4shared.com/img/fEbJqOum/s7/13feaf0c8c0/Search")]
|
||||
@@ -144,7 +145,7 @@ def peliculas(item):
|
||||
for scrapedurl, scrapedthumbnail, scrapedtitle in matches:
|
||||
scrapedtitle = scrapertools.decodeHtmlentities(scrapedtitle).strip()
|
||||
year = scrapertools.find_single_match(scrapedtitle, r'\((\d{4})\)')
|
||||
scrapedtitle = scrapedtitle.replace(year, color(year, "red"))
|
||||
scrapedtitle = scrapedtitle.replace(year, support.color(year, "red"))
|
||||
|
||||
# Bypass fake links
|
||||
html = httptools.downloadpage(scrapedurl).data
|
||||
@@ -204,11 +205,3 @@ def findvideos(item):
|
||||
videoitem.thumbnail = item.thumbnail
|
||||
videoitem.channel = item.channel
|
||||
return itemlist
|
||||
|
||||
# ================================================================================================================
|
||||
|
||||
# ----------------------------------------------------------------------------------------------------------------
|
||||
def color(text, color):
|
||||
return "[COLOR "+color+"]"+text+"[/COLOR]"
|
||||
|
||||
# ================================================================================================================
|
||||
|
||||
@@ -201,7 +201,7 @@ def select(item):
|
||||
def findvideos(item): # Questa def. deve sempre essere nominata findvideos
|
||||
logger.info('[cinemalibero.py] findvideos')
|
||||
itemlist = []
|
||||
# import web_pdb; web_pdb.set_trace()
|
||||
|
||||
if item.contentType == 'episode':
|
||||
data = item.url.lower()
|
||||
block = scrapertools.find_single_match(data,r'>streaming.*?<\/strong>*?<\/h2>(.*?)<\/div>')
|
||||
|
||||
@@ -8,6 +8,7 @@ from platformcode import logger
|
||||
from core import httptools
|
||||
from core import scrapertools
|
||||
from core.item import Item
|
||||
from channels import support
|
||||
|
||||
|
||||
|
||||
@@ -19,13 +20,13 @@ def mainlist(item):
|
||||
logger.info()
|
||||
itemlist = [Item(channel=item.channel,
|
||||
action="episodi",
|
||||
title=color("Dragon Ball Kai", "azure"),
|
||||
title=support.color("Dragon Ball Kai", "azure"),
|
||||
url="%s/dragon-ball-kai-episodi/" % host,
|
||||
extra="Kai",
|
||||
show="Dragon Ball Kai",
|
||||
thumbnail="https://www.dragonballforever.it/wp-content/uploads/2016/11/dragonball_kai_cover.jpg"),
|
||||
Item(channel=item.channel,
|
||||
title=color("Dragon Ball Super", "azure"),
|
||||
title=support.color("Dragon Ball Super", "azure"),
|
||||
action="episodi",
|
||||
url="%s/dragon-ball-super/" % host,
|
||||
extra="Super",
|
||||
@@ -52,7 +53,7 @@ def episodi(item):
|
||||
itemlist.append(
|
||||
Item(channel=item.channel,
|
||||
action="findvideos",
|
||||
title=re.sub(r'\d+', 'Episodio: %s' % color(epnumber, 'red'), scrapedtitle),
|
||||
title=re.sub(r'\d+', 'Episodio: %s' % support.color(epnumber, 'red'), scrapedtitle),
|
||||
fulltitle="Dragon Ball %s Episodio: %s" % (item.extra, scrapedtitle),
|
||||
url=scrapedurl,
|
||||
extra=item.extra,
|
||||
@@ -79,18 +80,10 @@ def findvideos(item):
|
||||
itemlist.append(
|
||||
Item(channel=item.channel,
|
||||
action="play",
|
||||
title="%s [.%s]" % (color(item.show, 'azure'), color(item.url.split('.')[-1], 'orange')),
|
||||
fulltitle=color(item.fulltitle, 'orange') if 'Super' in item.extra else color(item.fulltitle, 'deepskyblue'),
|
||||
title="%s [.%s]" % (support.color(item.show, 'azure'), support.color(item.url.split('.')[-1], 'orange')),
|
||||
fulltitle=support.color(item.fulltitle, 'orange') if 'Super' in item.extra else support.color(item.fulltitle, 'deepskyblue'),
|
||||
url=item.url,
|
||||
show=item.show,
|
||||
extra=item.extra,
|
||||
thumbnail=item.thumbnail))
|
||||
return itemlist
|
||||
|
||||
# ================================================================================================================
|
||||
|
||||
# ----------------------------------------------------------------------------------------------------------------
|
||||
def color(text, color):
|
||||
return "[COLOR "+color+"]"+text+"[/COLOR]"
|
||||
|
||||
# ================================================================================================================
|
||||
|
||||
@@ -174,8 +174,7 @@ def episodios(item):
|
||||
|
||||
for match in matches:
|
||||
season_title = match.group()
|
||||
# import web_pdb;
|
||||
# web_pdb.set_trace()
|
||||
|
||||
if season_title != '':
|
||||
lang_titles.append('SUB ITA' if 'SUB' in season_title.upper() else 'ITA')
|
||||
starts.append(match.end())
|
||||
|
||||
@@ -31,32 +31,32 @@ def mainlist(item):
|
||||
autoplay.init(item.channel, list_servers, list_quality)
|
||||
itemlist = [Item(channel=item.channel,
|
||||
action="peliculas",
|
||||
title=color("Home", "orange"),
|
||||
title=support.color("Home", "orange"),
|
||||
url=host,
|
||||
thumbnail="http://orig03.deviantart.net/6889/f/2014/079/7/b/movies_and_popcorn_folder_icon_by_matheusgrilo-d7ay4tw.png"),
|
||||
Item(channel=item.channel,
|
||||
action="annoattuale",
|
||||
title=color("Film di quest'anno", "azure"),
|
||||
title=support.color("Film di quest'anno", "azure"),
|
||||
url=host,
|
||||
thumbnail="http://orig03.deviantart.net/6889/f/2014/079/7/b/movies_and_popcorn_folder_icon_by_matheusgrilo-d7ay4tw.png"),
|
||||
Item(channel=item.channel,
|
||||
action="categorie",
|
||||
title=color("Categorie", "azure"),
|
||||
title=support.color("Categorie", "azure"),
|
||||
url=host,
|
||||
thumbnail="http://orig03.deviantart.net/6889/f/2014/079/7/b/movies_and_popcorn_folder_icon_by_matheusgrilo-d7ay4tw.png"),
|
||||
Item(channel=item.channel,
|
||||
action="peranno",
|
||||
title=color("Per anno", "azure"),
|
||||
title=support.color("Per anno", "azure"),
|
||||
url=host,
|
||||
thumbnail="http://orig03.deviantart.net/6889/f/2014/079/7/b/movies_and_popcorn_folder_icon_by_matheusgrilo-d7ay4tw.png"),
|
||||
Item(channel=item.channel,
|
||||
action="perpaese",
|
||||
title=color("Per paese", "azure"),
|
||||
title=support.color("Per paese", "azure"),
|
||||
url=host,
|
||||
thumbnail="http://orig03.deviantart.net/6889/f/2014/079/7/b/movies_and_popcorn_folder_icon_by_matheusgrilo-d7ay4tw.png"),
|
||||
Item(channel=item.channel,
|
||||
action="search",
|
||||
title=color("Cerca ...", "yellow"),
|
||||
title=support.color("Cerca ...", "yellow"),
|
||||
extra="movie",
|
||||
thumbnail="http://orig03.deviantart.net/6889/f/2014/079/7/b/movies_and_popcorn_folder_icon_by_matheusgrilo-d7ay4tw.png")]
|
||||
|
||||
@@ -227,7 +227,7 @@ def peliculas(item):
|
||||
Item(channel=item.channel,
|
||||
action="findvideos",
|
||||
contentType="movie",
|
||||
title=scrapedtitle.replace(year, color("%s" % year, "red")),
|
||||
title=scrapedtitle.replace(year, support.color("%s" % year, "red")),
|
||||
fulltitle=cleantitle,
|
||||
text_color="azure",
|
||||
url=scrapedurl,
|
||||
@@ -295,11 +295,3 @@ def findvideos(item):
|
||||
action="add_pelicula_to_library", extra="findvideos", contentTitle=item.contentTitle))
|
||||
|
||||
return itemlist
|
||||
|
||||
# ================================================================================================================
|
||||
|
||||
# ----------------------------------------------------------------------------------------------------------------
|
||||
def color(text, color):
|
||||
return "[COLOR "+color+"]"+text+"[/COLOR]"
|
||||
|
||||
# ================================================================================================================
|
||||
|
||||
@@ -8,7 +8,7 @@ import urlparse
|
||||
|
||||
from channelselector import get_thumb
|
||||
from channels import autoplay
|
||||
from channels import filtertools
|
||||
from channels import filtertools, support
|
||||
from core import scrapertools, servertools, httptools
|
||||
from platformcode import logger, config
|
||||
from core.item import Item
|
||||
@@ -196,54 +196,7 @@ def cerca(item):
|
||||
def findvideos(item):
|
||||
logger.info('[filmsenzalimiti.py] findvideos')
|
||||
|
||||
itemlist = []
|
||||
|
||||
# Carica la pagina
|
||||
data = httptools.downloadpage(item.url).data.replace('\t', '').replace('\n', '')
|
||||
logger.info('[filmsenzalimiti.py] findvideos page download= '+data)
|
||||
|
||||
patron = r'Streaming in HD<\/a><\/li><\/ul><br><p><iframe width="100%" height="430px" src="([^"]+)"'
|
||||
url = scrapertools.find_single_match(data, patron)
|
||||
|
||||
if 'hdpass' in url:
|
||||
data = httptools.downloadpage('http:%s' % url if 'http' not in url else url).data
|
||||
|
||||
start = data.find('<div class="row mobileRes">')
|
||||
end = data.find('<div id="playerFront">', start)
|
||||
data = data[start:end]
|
||||
|
||||
patron_res = '<div class="row mobileRes">(.*?)</div>'
|
||||
patron_mir = '<div class="row mobileMirrs">(.*?)</div>'
|
||||
patron_media = r'<input type="hidden" name="urlEmbed" data-mirror="[^"]+" id="urlEmbed" value="([^"]+)"[^>]+>'
|
||||
|
||||
res = scrapertools.find_single_match(data, patron_res)
|
||||
|
||||
for res_url, resolution in scrapertools.find_multiple_matches(res, '<option[^v]+value="([^"]*)">([^<]*)</option>'):
|
||||
res_url = urlparse.urljoin(url, res_url)
|
||||
data = httptools.downloadpage('http:%s' % res_url if 'http' not in res_url else res_url).data.replace('\n', '')
|
||||
|
||||
mir = scrapertools.find_single_match(data, patron_mir)
|
||||
|
||||
for mir_url, server in scrapertools.find_multiple_matches(mir, '<option[^v]+value="([^"]*)">([^<]*)</value>'):
|
||||
mir_url = urlparse.urljoin(url, mir_url)
|
||||
data = httptools.downloadpage('http:%s' % mir_url if 'http' not in mir_url else mir_url).data.replace('\n', '')
|
||||
|
||||
for media_url in re.compile(patron_media).findall(data):
|
||||
scrapedurl = url_decode(media_url)
|
||||
logger.info(scrapedurl)
|
||||
itemlist.append(
|
||||
Item(channel=item.channel,
|
||||
action="play",
|
||||
title='[[COLOR green]%s[/COLOR]][[COLOR orange]%s[/COLOR]] %s' % (resolution, server, item.title),
|
||||
url=scrapedurl,
|
||||
server=server,
|
||||
fulltitle=item.fulltitle,
|
||||
thumbnail=item.thumbnail,
|
||||
show=item.show,
|
||||
plot=item.plot,
|
||||
quality=resolution,
|
||||
contentType=item.contentType,
|
||||
folder=False))
|
||||
itemlist = support.hdpass_get_servers(item)
|
||||
|
||||
# Link Aggiungi alla Libreria
|
||||
if item.contentType == 'movie':
|
||||
@@ -270,30 +223,6 @@ def play(item):
|
||||
|
||||
return itemlist
|
||||
|
||||
def url_decode(url_enc):
|
||||
lenght = len(url_enc)
|
||||
if lenght % 2 == 0:
|
||||
len2 = lenght / 2
|
||||
first = url_enc[0:len2]
|
||||
last = url_enc[len2:lenght]
|
||||
url_enc = last + first
|
||||
reverse = url_enc[::-1]
|
||||
return base64.b64decode(reverse)
|
||||
|
||||
last_car = url_enc[lenght - 1]
|
||||
url_enc[lenght - 1] = ' '
|
||||
url_enc = url_enc.strip()
|
||||
len1 = len(url_enc)
|
||||
len2 = len1 / 2
|
||||
first = url_enc[0:len2]
|
||||
last = url_enc[len2:len1]
|
||||
url_enc = last + first
|
||||
reverse = url_enc[::-1]
|
||||
reverse = reverse + last_car
|
||||
return base64.b64decode(reverse)
|
||||
|
||||
|
||||
|
||||
def newest(categoria):
|
||||
logger.info('[filmsenzalimiti.py] newest' + categoria)
|
||||
itemlist = []
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
import re
|
||||
|
||||
from channels import autoplay
|
||||
from channels import filtertools
|
||||
from channels import filtertools, support
|
||||
from core import scrapertools, servertools, httptools
|
||||
from core.item import Item
|
||||
from core import tmdb
|
||||
@@ -29,17 +29,17 @@ def mainlist(item):
|
||||
logger.info("[FilmStreamingGratis.py]==> mainlist")
|
||||
itemlist = [Item(channel=item.channel,
|
||||
action="ultimifilm",
|
||||
title=color("Ultimi Film", "azure"),
|
||||
title=support.color("Ultimi Film", "azure"),
|
||||
url=host,
|
||||
thumbnail="http://orig03.deviantart.net/6889/f/2014/079/7/b/movies_and_popcorn_folder_icon_by_matheusgrilo-d7ay4tw.png"),
|
||||
Item(channel=item.channel,
|
||||
action="categorie",
|
||||
title=color("Categorie", "azure"),
|
||||
title=support.color("Categorie", "azure"),
|
||||
url=host,
|
||||
thumbnail="http://orig03.deviantart.net/6889/f/2014/079/7/b/movies_and_popcorn_folder_icon_by_matheusgrilo-d7ay4tw.png"),
|
||||
Item(channel=item.channel,
|
||||
action="search",
|
||||
title=color("Cerca film ...", "yellow"),
|
||||
title=support.color("Cerca film ...", "yellow"),
|
||||
extra="movie",
|
||||
thumbnail="http://dc467.4shared.com/img/fEbJqOum/s7/13feaf0c8c0/Search")]
|
||||
|
||||
@@ -195,7 +195,7 @@ def findvideos(item):
|
||||
|
||||
for videoitem in itemlist:
|
||||
server = re.sub(r'[-\[\]\s]+', '', videoitem.title)
|
||||
videoitem.title = "".join(["[%s] " % color(server.capitalize(), 'orange'), item.title])
|
||||
videoitem.title = "".join(["[%s] " % support.color(server.capitalize(), 'orange'), item.title])
|
||||
videoitem.fulltitle = item.fulltitle
|
||||
videoitem.show = item.show
|
||||
videoitem.thumbnail = item.thumbnail
|
||||
@@ -225,7 +225,3 @@ def findvideos(item):
|
||||
return itemlist
|
||||
|
||||
|
||||
|
||||
def color(text, color):
|
||||
return "[COLOR %s]%s[/COLOR]" % (color, text)
|
||||
|
||||
|
||||
@@ -10,7 +10,7 @@ from core import httptools, scrapertools, servertools
|
||||
from core.item import Item
|
||||
from core import tmdb
|
||||
from platformcode import logger, config
|
||||
|
||||
from channels import support
|
||||
|
||||
|
||||
host = "http://www.guardaserie.watch"
|
||||
@@ -23,27 +23,27 @@ def mainlist(item):
|
||||
logger.info("[GuardaSerieClick.py]==> mainlist")
|
||||
itemlist = [Item(channel=item.channel,
|
||||
action="nuoveserie",
|
||||
title=color("Nuove serie TV", "orange"),
|
||||
title=support.color("Nuove serie TV", "orange"),
|
||||
url="%s/lista-serie-tv" % host,
|
||||
thumbnail="http://orig03.deviantart.net/6889/f/2014/079/7/b/movies_and_popcorn_folder_icon_by_matheusgrilo-d7ay4tw.png"),
|
||||
Item(channel=item.channel,
|
||||
action="serietvaggiornate",
|
||||
title=color("Serie TV Aggiornate", "azure"),
|
||||
title=support.color("Serie TV Aggiornate", "azure"),
|
||||
url="%s/lista-serie-tv" % host,
|
||||
thumbnail="http://orig03.deviantart.net/6889/f/2014/079/7/b/movies_and_popcorn_folder_icon_by_matheusgrilo-d7ay4tw.png"),
|
||||
Item(channel=item.channel,
|
||||
action="lista_serie",
|
||||
title=color("Anime", "azure"),
|
||||
title=support.color("Anime", "azure"),
|
||||
url="%s/category/animazione/" % host,
|
||||
thumbnail="http://orig03.deviantart.net/6889/f/2014/079/7/b/movies_and_popcorn_folder_icon_by_matheusgrilo-d7ay4tw.png"),
|
||||
Item(channel=item.channel,
|
||||
action="categorie",
|
||||
title=color("Categorie", "azure"),
|
||||
title=support.color("Categorie", "azure"),
|
||||
url=host,
|
||||
thumbnail="http://orig03.deviantart.net/6889/f/2014/079/7/b/movies_and_popcorn_folder_icon_by_matheusgrilo-d7ay4tw.png"),
|
||||
Item(channel=item.channel,
|
||||
action="search",
|
||||
title=color("Cerca ...", "yellow"),
|
||||
title=support.color("Cerca ...", "yellow"),
|
||||
extra="serie",
|
||||
thumbnail="http://dc467.4shared.com/img/fEbJqOum/s7/13feaf0c8c0/Search")]
|
||||
|
||||
@@ -266,7 +266,7 @@ def findepvideos(item):
|
||||
|
||||
for videoitem in itemlist:
|
||||
server = re.sub(r'[-\[\]\s]+', '', videoitem.title).capitalize()
|
||||
videoitem.title = "".join(["[%s] " % color(server.capitalize(), 'orange'), item.title])
|
||||
videoitem.title = "".join(["[%s] " % support.color(server.capitalize(), 'orange'), item.title])
|
||||
videoitem.fulltitle = item.fulltitle
|
||||
videoitem.thumbnail = item.thumbnail
|
||||
videoitem.show = item.show
|
||||
@@ -286,7 +286,7 @@ def findvideos(item):
|
||||
|
||||
for videoitem in itemlist:
|
||||
server = re.sub(r'[-\[\]\s]+', '', videoitem.title).capitalize()
|
||||
videoitem.title = "".join(["[%s] " % color(server.capitalize(), 'orange'), item.title])
|
||||
videoitem.title = "".join(["[%s] " % support.color(server.capitalize(), 'orange'), item.title])
|
||||
videoitem.fulltitle = item.fulltitle
|
||||
videoitem.thumbnail = item.thumbnail
|
||||
videoitem.show = item.show
|
||||
@@ -294,12 +294,3 @@ def findvideos(item):
|
||||
videoitem.channel = item.channel
|
||||
|
||||
return itemlist
|
||||
|
||||
|
||||
# ================================================================================================================
|
||||
|
||||
# ----------------------------------------------------------------------------------------------------------------
|
||||
def color(text, color):
|
||||
return "[COLOR %s]%s[/COLOR]" % (color, text)
|
||||
|
||||
# ================================================================================================================
|
||||
|
||||
@@ -8,7 +8,7 @@ import re
|
||||
import urlparse
|
||||
|
||||
from channels import autoplay
|
||||
from channels import filtertools
|
||||
from channels import filtertools, support
|
||||
from core import scrapertools, servertools, httptools
|
||||
from core.item import Item
|
||||
from core import tmdb
|
||||
@@ -350,7 +350,7 @@ def findvid_series(item):
|
||||
data = httptools.downloadpage(urlparse.urljoin(url, mir_url), headers=headers).data.replace('\n', '')
|
||||
|
||||
for media_label, media_url in re.compile(patron_media).findall(data):
|
||||
urls.append(url_decode(media_url))
|
||||
urls.append(support.url_decode(media_url))
|
||||
|
||||
itemlist = servertools.find_video_items(data='\n'.join(urls))
|
||||
for videoitem in itemlist:
|
||||
@@ -364,24 +364,3 @@ def findvid_series(item):
|
||||
|
||||
return itemlist
|
||||
|
||||
def url_decode(url_enc):
|
||||
lenght = len(url_enc)
|
||||
if lenght % 2 == 0:
|
||||
len2 = lenght / 2
|
||||
first = url_enc[0:len2]
|
||||
last = url_enc[len2:lenght]
|
||||
url_enc = last + first
|
||||
reverse = url_enc[::-1]
|
||||
return base64.b64decode(reverse)
|
||||
|
||||
last_car = url_enc[lenght - 1]
|
||||
url_enc[lenght - 1] = ' '
|
||||
url_enc = url_enc.strip()
|
||||
len1 = len(url_enc)
|
||||
len2 = len1 / 2
|
||||
first = url_enc[0:len2]
|
||||
last = url_enc[len2:len1]
|
||||
url_enc = last + first
|
||||
reverse = url_enc[::-1]
|
||||
reverse = reverse + last_car
|
||||
return base64.b64decode(reverse)
|
||||
|
||||
@@ -12,6 +12,7 @@ from core import servertools
|
||||
from core.item import Item
|
||||
from core import tmdb
|
||||
from platformcode import logger, config
|
||||
from channels import support
|
||||
|
||||
|
||||
|
||||
@@ -294,71 +295,8 @@ def fichas(item):
|
||||
def findvideos(item):
|
||||
logger.info("[italiafilmvideohd.py] findvideos")
|
||||
|
||||
itemlist = []
|
||||
|
||||
# Carica la pagina
|
||||
data = httptools.downloadpage(item.url, headers=headers).data.replace('\n', '')
|
||||
|
||||
patron = r'<iframe width=".+?" height=".+?" src="([^"]+)" allowfullscreen frameborder="0">'
|
||||
url = scrapertools.find_single_match(data, patron).replace("?ita", "")
|
||||
|
||||
if 'hdpass' in url:
|
||||
data = httptools.downloadpage(url, headers=headers).data
|
||||
|
||||
start = data.find('<div class="row mobileRes">')
|
||||
end = data.find('<div id="playerFront">', start)
|
||||
data = data[start:end]
|
||||
|
||||
patron_res = r'<div class="row mobileRes">([\s\S]*)<\/div>'
|
||||
patron_mir = r'<div class="row mobileMirrs">([\s\S]*)<\/div>'
|
||||
patron_media = r'<input type="hidden" name="urlEmbed" data-mirror="([^"]+)" id="urlEmbed" value="([^"]+)"[^>]+>'
|
||||
|
||||
res = scrapertools.find_single_match(data, patron_res)
|
||||
|
||||
urls = []
|
||||
for res_url, res_video in scrapertools.find_multiple_matches(res, '<option.*?value="([^"]+?)">([^<]+?)</option>'):
|
||||
|
||||
data = httptools.downloadpage(urlparse.urljoin(url, res_url), headers=headers).data.replace('\n', '')
|
||||
|
||||
mir = scrapertools.find_single_match(data, patron_mir)
|
||||
|
||||
for mir_url in scrapertools.find_multiple_matches(mir, '<option.*?value="([^"]+?)">[^<]+?</value>'):
|
||||
|
||||
data = httptools.downloadpage(urlparse.urljoin(url, mir_url), headers=headers).data.replace('\n', '')
|
||||
|
||||
for media_label, media_url in re.compile(patron_media).findall(data):
|
||||
urls.append(url_decode(media_url))
|
||||
|
||||
itemlist = servertools.find_video_items(data='\n'.join(urls))
|
||||
for videoitem in itemlist:
|
||||
videoitem.title = item.title + videoitem.title
|
||||
videoitem.fulltitle = item.fulltitle
|
||||
videoitem.thumbnail = item.thumbnail
|
||||
videoitem.show = item.show
|
||||
videoitem.plot = item.plot
|
||||
videoitem.channel = item.channel
|
||||
itemlist = support.hdpass_get_servers(item)
|
||||
|
||||
return itemlist
|
||||
|
||||
|
||||
def url_decode(url_enc):
|
||||
lenght = len(url_enc)
|
||||
if lenght % 2 == 0:
|
||||
len2 = lenght / 2
|
||||
first = url_enc[0:len2]
|
||||
last = url_enc[len2:lenght]
|
||||
url_enc = last + first
|
||||
reverse = url_enc[::-1]
|
||||
return base64.b64decode(reverse)
|
||||
|
||||
last_car = url_enc[lenght - 1]
|
||||
url_enc[lenght - 1] = ' '
|
||||
url_enc = url_enc.strip()
|
||||
len1 = len(url_enc)
|
||||
len2 = len1 / 2
|
||||
first = url_enc[0:len2]
|
||||
last = url_enc[len2:len1]
|
||||
url_enc = last + first
|
||||
reverse = url_enc[::-1]
|
||||
reverse = reverse + last_car
|
||||
return base64.b64decode(reverse)
|
||||
|
||||
@@ -10,6 +10,7 @@ from core import httptools, scrapertools, servertools
|
||||
from core.item import Item
|
||||
from core import tmdb
|
||||
from platformcode import logger, config
|
||||
from channels import support
|
||||
|
||||
host = "http://mondolunatico.org"
|
||||
|
||||
@@ -171,7 +172,7 @@ def findvideos(item):
|
||||
itemlist = servertools.find_video_items(data=data)
|
||||
for videoitem in itemlist:
|
||||
server = re.sub(r'[-\[\]\s]+', '', videoitem.title).capitalize()
|
||||
videoitem.title = "".join(["[%s] " % color(server, 'orange'), item.title])
|
||||
videoitem.title = "".join(["[%s] " % support.color(server, 'orange'), item.title])
|
||||
videoitem.fulltitle = item.fulltitle
|
||||
videoitem.thumbnail = item.thumbnail
|
||||
videoitem.show = item.show
|
||||
@@ -180,7 +181,3 @@ def findvideos(item):
|
||||
videoitem.contentType = item.contentType
|
||||
|
||||
return itemlist
|
||||
|
||||
|
||||
def color(text, color):
|
||||
return "[COLOR " + color + "]" + text + "[/COLOR]"
|
||||
|
||||
@@ -9,7 +9,7 @@ import re
|
||||
import urlparse
|
||||
|
||||
from channels import autoplay
|
||||
from channels import filtertools
|
||||
from channels import filtertools, support
|
||||
from core import scrapertools, servertools, httptools
|
||||
from platformcode import logger, config
|
||||
from core.item import Item
|
||||
@@ -190,50 +190,7 @@ def findvideos(item):
|
||||
|
||||
itemlist = []
|
||||
|
||||
# Carica la pagina
|
||||
data = httptools.downloadpage(item.url).data.replace('\n', '')
|
||||
|
||||
patron = r'<iframe[^s]+src="([^"]+)" allowfullscreen[^>]+>'
|
||||
url = scrapertools.find_single_match(data, patron)
|
||||
|
||||
if 'hdpass' in url:
|
||||
data = httptools.downloadpage("http:%s" % url if 'http' not in url else url).data
|
||||
|
||||
start = data.find('<div class="row mobileRes">')
|
||||
end = data.find('<div id="playerFront">', start)
|
||||
data = data[start:end]
|
||||
|
||||
patron_res = '<div class="row mobileRes">(.*?)</div>'
|
||||
patron_mir = '<div class="row mobileMirrs">(.*?)</div>'
|
||||
patron_media = r'<input type="hidden" name="urlEmbed" data-mirror="[^"]+" id="urlEmbed" value="([^"]+)"[^>]+>'
|
||||
|
||||
res = scrapertools.find_single_match(data, patron_res)
|
||||
|
||||
urls = []
|
||||
for res_url in scrapertools.find_multiple_matches(res, '<option[^v]+value="([^"]*)">[^<]*</option>'):
|
||||
res_url = urlparse.urljoin(url, res_url)
|
||||
data = httptools.downloadpage("http:%s" % res_url if 'http' not in res_url else res_url).data.replace('\n', '')
|
||||
|
||||
mir = scrapertools.find_single_match(data, patron_mir)
|
||||
|
||||
for mir_url in scrapertools.find_multiple_matches(mir, '<option[^v]+value="([^"]*)">[^<]*</value>'):
|
||||
mir_url = urlparse.urljoin(url, mir_url)
|
||||
data = httptools.downloadpage("http:%s" % mir_url if 'http' not in mir_url else mir_url).data.replace('\n', '')
|
||||
|
||||
for media_url in re.compile(patron_media).findall(data):
|
||||
urls.append(url_decode(media_url))
|
||||
|
||||
itemlist = servertools.find_video_items(data='\n'.join(urls))
|
||||
for videoitem in itemlist:
|
||||
server = re.sub(r'[-\[\]\s]+', '', videoitem.title).capitalize()
|
||||
videoitem.title = "[[COLOR orange]%s[/COLOR]] %s" % (server, item.title)
|
||||
videoitem.fulltitle = item.fulltitle
|
||||
videoitem.thumbnail = item.thumbnail
|
||||
videoitem.show = item.show
|
||||
videoitem.plot = item.plot
|
||||
videoitem.channel = __channel__
|
||||
videoitem.contentType = item.contentType
|
||||
videoitem.language = IDIOMAS['Italiano']
|
||||
itemlist = support.hdpass_get_servers(item)
|
||||
|
||||
# Requerido para Filtrar enlaces
|
||||
|
||||
@@ -257,29 +214,6 @@ def findvideos(item):
|
||||
return itemlist
|
||||
|
||||
|
||||
def url_decode(url_enc):
|
||||
lenght = len(url_enc)
|
||||
if lenght % 2 == 0:
|
||||
len2 = lenght / 2
|
||||
first = url_enc[0:len2]
|
||||
last = url_enc[len2:lenght]
|
||||
url_enc = last + first
|
||||
reverse = url_enc[::-1]
|
||||
return base64.b64decode(reverse)
|
||||
|
||||
last_car = url_enc[lenght - 1]
|
||||
url_enc[lenght - 1] = ' '
|
||||
url_enc = url_enc.strip()
|
||||
len1 = len(url_enc)
|
||||
len2 = len1 / 2
|
||||
first = url_enc[0:len2]
|
||||
last = url_enc[len2:len1]
|
||||
url_enc = last + first
|
||||
reverse = url_enc[::-1]
|
||||
reverse = reverse + last_car
|
||||
return base64.b64decode(reverse)
|
||||
|
||||
|
||||
def newest(categoria):
|
||||
logger.info("[seriehd] newest" + categoria)
|
||||
itemlist = []
|
||||
|
||||
@@ -26,27 +26,27 @@ def mainlist(item):
|
||||
logger.info("[SerieTVU.py]==> mainlist")
|
||||
itemlist = [Item(channel=item.channel,
|
||||
action="lista_serie",
|
||||
title=color("Nuove serie TV", "orange"),
|
||||
title=support.color("Nuove serie TV", "orange"),
|
||||
url="%s/category/serie-tv" % host,
|
||||
thumbnail="http://orig03.deviantart.net/6889/f/2014/079/7/b/movies_and_popcorn_folder_icon_by_matheusgrilo-d7ay4tw.png"),
|
||||
Item(channel=item.channel,
|
||||
action="latestep",
|
||||
title=color("Nuovi Episodi", "azure"),
|
||||
title=support.color("Nuovi Episodi", "azure"),
|
||||
url="%s/ultimi-episodi" % host,
|
||||
thumbnail="http://orig03.deviantart.net/6889/f/2014/079/7/b/movies_and_popcorn_folder_icon_by_matheusgrilo-d7ay4tw.png"),
|
||||
Item(channel=item.channel,
|
||||
action="lista_serie",
|
||||
title=color("Serie TV Aggiornate", "azure"),
|
||||
title=support.color("Serie TV Aggiornate", "azure"),
|
||||
url="%s/ultimi-episodi" % host,
|
||||
thumbnail="http://orig03.deviantart.net/6889/f/2014/079/7/b/movies_and_popcorn_folder_icon_by_matheusgrilo-d7ay4tw.png"),
|
||||
Item(channel=item.channel,
|
||||
action="categorie",
|
||||
title=color("Categorie", "azure"),
|
||||
title=support.color("Categorie", "azure"),
|
||||
url=host,
|
||||
thumbnail="http://orig03.deviantart.net/6889/f/2014/079/7/b/movies_and_popcorn_folder_icon_by_matheusgrilo-d7ay4tw.png"),
|
||||
Item(channel=item.channel,
|
||||
action="search",
|
||||
title=color("Cerca ...", "yellow"),
|
||||
title=support.color("Cerca ...", "yellow"),
|
||||
extra="tvshow",
|
||||
thumbnail="http://dc467.4shared.com/img/fEbJqOum/s7/13feaf0c8c0/Search")]
|
||||
|
||||
@@ -288,7 +288,7 @@ def findepisodevideo(item):
|
||||
# ================================================================================================================
|
||||
|
||||
# ----------------------------------------------------------------------------------------------------------------
|
||||
def color(text, color):
|
||||
return "[COLOR %s]%s[/COLOR]" % (color, text)
|
||||
\r
|
||||
|
||||
|
||||
# ================================================================================================================
|
||||
|
||||
@@ -192,5 +192,5 @@ def findvideos(item):
|
||||
videoitem.channel = item.channel
|
||||
return itemlist
|
||||
|
||||
def color(text, color):
|
||||
return "[COLOR %s]%s[/COLOR]" % (color, text)
|
||||
\r
|
||||
|
||||
|
||||
@@ -23,18 +23,18 @@ headers = [['Referer', host]]
|
||||
def mainlist(item):
|
||||
logger.info("[UMSFunSub.py]==> mainlist")
|
||||
itemlist = [Item(channel=item.channel,
|
||||
title=color("Progetti", "azure"),
|
||||
title=support.color("Progetti", "azure"),
|
||||
action="progetti",
|
||||
plot="- In corso\n- Conclusi",
|
||||
url=makeurl("progetti-fansub-anime-giapponesi-attivi-shoujo-shounen-manga.php"),
|
||||
thumbnail="http://www.hiumi.it/public/forum/styles/art_deluxe/imageset/logo.png"),
|
||||
Item(channel=item.channel,
|
||||
title=color("Lista Completa", "azure"),
|
||||
title=support.color("Lista Completa", "azure"),
|
||||
action="lista_anime",
|
||||
url=makeurl("streaming-fansub-gratuiti.php?categoria=In_corso&cat=Conclusi"),
|
||||
thumbnail="http://www.hiumi.it/public/forum/styles/art_deluxe/imageset/logo.png"),
|
||||
Item(channel=item.channel,
|
||||
title=color("Cerca ...", "yellow"),
|
||||
title=support.color("Cerca ...", "yellow"),
|
||||
action="search",
|
||||
thumbnail="http://dc467.4shared.com/img/fEbJqOum/s7/13feaf0c8c0/Search")
|
||||
]
|
||||
@@ -96,7 +96,7 @@ def lista_anime(item):
|
||||
Item(channel=item.channel,
|
||||
action="episodi",
|
||||
title="%s %s %s" % (
|
||||
color(scrapedtitle, "azure"), color(" | ", "red"), color(scrapeddetails, "deepskyblue")),
|
||||
color(scrapedtitle, "azure"), support.color(" | ", "red"), color(scrapeddetails, "deepskyblue")),
|
||||
fulltitle=scrapedtitle,
|
||||
show=scrapedtitle,
|
||||
url=scrapedurl,
|
||||
@@ -148,7 +148,7 @@ def findvideos(item):
|
||||
|
||||
itemlist.append(Item(channel=item.channel,
|
||||
action="play",
|
||||
title="[%s] %s" % (color("." + estensionevideo, "orange"), item.title),
|
||||
title="[%s] %s" % (support.color("." + estensionevideo, "orange"), item.title),
|
||||
fulltitle=item.fulltitle,
|
||||
show=item.show,
|
||||
url=urlvideo,
|
||||
@@ -156,11 +156,6 @@ def findvideos(item):
|
||||
return itemlist
|
||||
|
||||
|
||||
|
||||
def color(text, color):
|
||||
return "[COLOR " + color + "]" + text + "[/COLOR]"
|
||||
|
||||
|
||||
def makeurl(text, title=""):
|
||||
if title == "":
|
||||
return host + "/" + text
|
||||
|
||||
@@ -27,8 +27,7 @@ def get_video_url(page_url, premium=False, user="", password="", video_password=
|
||||
|
||||
headers = [["User-Agent", "Mozilla/5.0 (Windows NT 6.1; rv:54.0) Gecko/20100101 Firefox/54.0"]]
|
||||
|
||||
# import web_pdb;
|
||||
# web_pdb.set_trace()
|
||||
|
||||
|
||||
# First access
|
||||
httptools.downloadpage("http://backin.net/s/streams.php?s=%s" % page_url, headers=headers)
|
||||
|
||||
@@ -9,7 +9,7 @@ from platformcode import logger
|
||||
|
||||
|
||||
def get_video_url(page_url, premium=False, user="", password="", video_password=""):
|
||||
# import web_pdb; web_pdb.set_trace()
|
||||
|
||||
encontrados = {
|
||||
'https://vcrypt.net/images/logo', 'https://vcrypt.net/css/out',
|
||||
'https://vcrypt.net/images/favicon', 'https://vcrypt.net/css/open',
|
||||
@@ -76,7 +76,7 @@ def get_video_url(page_url, premium=False, user="", password="", video_password=
|
||||
url = rdata.url
|
||||
|
||||
if "wstream" in url:
|
||||
# import web_pdb; web_pdb.set_trace()
|
||||
|
||||
url = url.replace("/video/", "/")
|
||||
|
||||
data = url
|
||||
|
||||
Reference in New Issue
Block a user