# -*- coding: utf-8 -*- # ------------------------------------------------------------ # Ringraziamo Icarus crew # Canale downloadme # Version: 201804162230 # ------------------------------------------------------------ import re from core import httptools, scrapertools from core import servertools from core.item import Item from core import tmdb from lib.unshortenit import unshorten from platformcode import logger, config from lib import unshortenit host = "https://www.downloadme.gratis" headers = [['Referer', host]] def mainlist(item): logger.info("[downloadme.py] mainlist") # Main options itemlist = [Item(channel=item.channel, action="peliculas", title="[COLOR azure]Film[/COLOR]", url="%s/category/film/" % host, extra="movie", 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="peliculas", # title="Serie TV", # text_color="azure", # url="%s/category/serie-tv/" % host, # extra="tv", # 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="peliculas", # title="Anime", # text_color="azure", # url="%s/category/anime/" % host, # extra="tv", # 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 azure]Categorie[/COLOR]", url="%s/" % host, extra="movie", thumbnail="http://orig03.deviantart.net/6889/f/2014/079/7/b/movies_and_popcorn_folder_icon_by_matheusgrilo-d7ay4tw.png")] return itemlist def categorie(item): logger.info("[downloadme.py] peliculas") itemlist = [] data = httptools.downloadpage(item.url, headers=headers).data blocco = scrapertools.find_single_match(data, '
') patron = '(.*?)' matches = re.compile(patron, re.DOTALL).findall(blocco) for scrapedurl, scrapedtitle in matches: itemlist.append( Item(channel=item.channel, action="peliculas", text_color="azure", fulltitle=scrapedtitle, show=scrapedtitle, title=scrapedtitle, url="%s/%s" % (host, scrapedurl), extra=item.extra, viewmode="movie_with_plot", Folder=True)) return itemlist def peliculas(item): logger.info("[downloadme.py] peliculas") itemlist = [] data = httptools.downloadpage(item.url, headers=headers).data #blocco = scrapertools.find_single_match(data, '