(.*?)
.*?' + patron += "(.*?)
(\d{4}) /.*?.*?'(\d+)'" + matches = re.compile(patron, re.DOTALL).findall(data) + + for scrapedthumbnail, scrapedurl, scrapedtitle, scrapedplot, year, video_id in matches: + + title = '%s [%s]' % (scrapedtitle, year) + contentTitle = scrapedtitle + thumbnail = scrapedthumbnail + url = scrapedurl + + itemlist.append(item.clone(action='findvideos', + title=title, + url=url, + thumbnail=thumbnail, + contentTitle=contentTitle, + video_id=video_id, + infoLabels={'year':year})) + + elif item.type == 'series': + patron = '(.*?)
(.*?)
(\d{4}) /' + matches = re.compile(patron, re.DOTALL).findall(data) + + for scrapedurl, scrapedthumbnail, scrapedtitle, scrapedplot, year in matches: + title = scrapedtitle + contentSerieName = scrapedtitle + thumbnail = scrapedthumbnail + url = scrapedurl + + itemlist.append(item.clone(action='seasons', + title=title, + url=url, + thumbnail=thumbnail, + plot=scrapedplot, + contentSerieName=contentSerieName, + infoLabels={'year':year})) + + tmdb.set_infoLabels(itemlist, seekTmdb=True) + # Paginación + + url_next_page = scrapertools.find_single_match(data,"") + if url_next_page: + itemlist.append(item.clone(title="Siguiente >>", url=url_next_page, action='list_all')) + + return itemlist + +def seasons(item): + logger.info() + + itemlist=[] + + data=get_source(item.url) + patron='|\s{2,}', "", data) + packed = scrapertools.find_single_match(data, '(eval\(.*?);var') + unpacked = jsunpack.unpack(packed) + logger.debug('unpacked %s' % unpacked) + server = scrapertools.find_single_match(unpacked, "src:.'(http://\D+)/") + id = scrapertools.find_single_match(unpacked, "src:.'http://\D+/.*?description:.'(.*?).'") + if server == '': + if 'powvideo' in unpacked: + id = scrapertools.find_single_match(unpacked ,",description:.'(.*?).'") + server= 'https://powvideo.net' + url = '%s/%s' % (server, id) + if server != '' and id != '': + language = IDIOMAS[video_info['idioma']] + quality = CALIDADES[video_info['calidad']] + title = ' [%s] [%s]' % (language, quality) + itemlist.append(Item(channel=item.channel, title='%s'+title, url=url, action='play', language=language, + quality=quality)) + + itmelist = servertools.get_servers_itemlist(itemlist, lambda i: i.title % i.server.capitalize()) + return sorted(itemlist, key=lambda i: i.language) + + +def search(item, texto): + logger.info() + texto = texto.replace(" ", "+") + item.url = item.url + texto + item.type = 'peliculas' + if texto != '': + return search_results(item) + else: + return [] + +def search_results(item): + logger.info() + + itemlist=[] + + data=get_source(item.url) + logger.debug(data) + patron = '
(.*?)
(.*?)
(\d{4})<' + matches = re.compile(patron, re.DOTALL).findall(data) + + for scrapedurl, content_type ,scrapedthumb, scrapedtitle, scrapedplot, year in matches: + + title = scrapedtitle + url = scrapedurl + thumbnail = scrapedthumb + plot = scrapedplot + if content_type != 'Serie': + action = 'findvideos' + else: + action = 'seasons' + + new_item=Item(channel=item.channel, title=title, url=url, thumbnail=thumbnail, plot=plot, + action=action, type=content_type, infoLabels={'year':year}) + if new_item.action == 'findvideos': + new_item.contentTitle = new_item.title + else: + new_item.contentSerieName = new_item.title + + itemlist.append(new_item) + + tmdb.set_infoLabels_itemlist(itemlist, seekTmdb=True) + + return itemlist + +def newest(categoria): + logger.info() + itemlist = [] + item = Item() + try: + if categoria in ['peliculas']: + item.url = host + 'peliculas' + elif categoria == 'infantiles': + item.url = host + 'peliculas/generos/animación' + elif categoria == 'terror': + item.url = host + 'peliculas/generos/terror' + item.type='peliculas' + itemlist = list_all(item) + if itemlist[-1].title == 'Siguiente >>': + itemlist.pop() + except: + import sys + for line in sys.exc_info(): + logger.error("{0}".format(line)) + return [] + + return itemlist diff --git a/plugin.video.alfa/channels/pelisr.json b/plugin.video.alfa/channels/pelisr.json new file mode 100644 index 00000000..92257e9e --- /dev/null +++ b/plugin.video.alfa/channels/pelisr.json @@ -0,0 +1,79 @@ +{ +"id": "pelisr", + "name": "PelisR", + "active": true, + "adult": false, + "language": ["lat", "cast", "vose"], + "thumbnail": "https://s22.postimg.cc/gcp2jqbs1/pelisr.png", + "banner": "", + "categories": [ + "movie", + "tvshow", + "direct" + ], + "settings": [ + { + "id": "include_in_global_search", + "type": "bool", + "label": "Incluir en busqueda global", + "default": true, + "enabled": true, + "visible": true + }, + { + "id": "filter_languages", + "type": "list", + "label": "Mostrar enlaces en idioma...", + "default": 0, + "enabled": true, + "visible": true, + "lvalues": [ + "No filtrar", + "Latino", + "Castellano", + "VOSE" + ] + }, + { + "id": "include_in_newest_peliculas", + "type": "bool", + "label": "Incluir en Novedades - Peliculas", + "default": true, + "enabled": true, + "visible": true + }, + { + "id": "include_in_newest_infantiles", + "type": "bool", + "label": "Incluir en Novedades - Infantiles", + "default": true, + "enabled": true, + "visible": true + }, + { + "id": "include_in_newest_terror", + "type": "bool", + "label": "Incluir en Novedades - terror", + "default": true, + "enabled": true, + "visible": true + }, + { + "id": "comprueba_enlaces", + "type": "bool", + "label": "Verificar si los enlaces existen", + "default": false, + "enabled": true, + "visible": true + }, + { + "id": "comprueba_enlaces_num", + "type": "list", + "label": "Número de enlaces a verificar", + "default": 1, + "enabled": true, + "visible": "eq(-1,true)", + "lvalues": [ "5", "10", "15", "20" ] + } + ] +} diff --git a/plugin.video.alfa/channels/pelisr.py b/plugin.video.alfa/channels/pelisr.py new file mode 100644 index 00000000..7d826449 --- /dev/null +++ b/plugin.video.alfa/channels/pelisr.py @@ -0,0 +1,366 @@ +# -*- coding: utf-8 -*- +# -*- Channel PoseidonHD -*- +# -*- Created for Alfa-addon -*- +# -*- By the Alfa Develop Group -*- + +import re +import urllib +import base64 + +from channelselector import get_thumb +from core import httptools +from core import jsontools +from core import scrapertools +from core import servertools +from core import tmdb +from lib import jsunpack +from core.item import Item +from channels import filtertools +from channels import autoplay +from platformcode import config, logger + + +IDIOMAS = {'mx': 'Latino', 'dk':'Latino', 'es': 'Castellano', 'en': 'VOSE', 'gb':'VOSE'} +list_language = IDIOMAS.values() + +list_quality = ['360P', '480P', '720P', '1080P'] + +list_servers = [ + 'directo', + 'openload', + 'rapidvideo' +] + +__comprueba_enlaces__ = config.get_setting('comprueba_enlaces', 'poseidonhd') +__comprueba_enlaces_num__ = config.get_setting('comprueba_enlaces_num', 'poseidonhd') + +host = 'https://pelisr.com/' + +def mainlist(item): + logger.info() + + autoplay.init(item.channel, list_servers, list_quality) + + itemlist = [] + + itemlist.append(Item(channel=item.channel, title='Peliculas', action='menu_movies', + thumbnail= get_thumb('movies', auto=True))) + itemlist.append(Item(channel=item.channel, title='Series', url=host+'tvshows', action='list_all', type='tvshows', + thumbnail= get_thumb('tvshows', auto=True))) + itemlist.append( + item.clone(title="Buscar", action="search", url=host + '?s=', thumbnail=get_thumb("search", auto=True), + extra='movie')) + + autoplay.show_option(item.channel, itemlist) + + return itemlist + +def menu_movies(item): + logger.info() + + itemlist=[] + + itemlist.append(Item(channel=item.channel, title='Todas', url=host + 'movies', action='list_all', + thumbnail=get_thumb('all', auto=True), type='movies')) + itemlist.append(Item(channel=item.channel, title='Genero', action='section', + thumbnail=get_thumb('genres', auto=True), type='movies')) + itemlist.append(Item(channel=item.channel, title='Por Año', action='section', + thumbnail=get_thumb('year', auto=True), type='movies')) + + return itemlist + +def get_source(url): + logger.info() + data = httptools.downloadpage(url).data + data = re.sub(r'"|\n|\r|\t| ||\s{2,}', "", data) + return data + + +def get_language(lang_data): + logger.info() + language = [] + logger.debug(lang_data) + lang_list = scrapertools.find_multiple_matches(lang_data, '/flags/(.*?).png\)') + for lang in lang_list: + if lang == 'en': + lang = 'vose' + if lang not in language: + language.append(lang) + return language + +def section(item): + logger.info() + itemlist=[] + duplicados=[] + data = get_source(host+'/'+item.type) + if 'Genero' in item.title: + patron = '
(.*?)
' + matches = re.compile(patron, re.DOTALL).findall(data) + + for scrapedurl, scrapedthumb, scrapedtitle, year, lang_data, scrapedplot in matches: + + title = scrapedtitle + url = scrapedurl + thumbnail = scrapedthumb + plot = scrapedplot + language = get_language(lang_data) + if language: + action = 'findvideos' + else: + action = 'seasons' + + new_item=Item(channel=item.channel, title=title, url=url, thumbnail=thumbnail, plot=plot, + action=action, + language=language, infoLabels={'year':year}) + if new_item.action == 'findvideos': + new_item.contentTitle = new_item.title + else: + new_item.contentSerieName = new_item.title + + itemlist.append(new_item) + + tmdb.set_infoLabels_itemlist(itemlist, seekTmdb=True) + + return itemlist + +def newest(categoria): + logger.info() + itemlist = [] + item = Item() + try: + if categoria in ['peliculas']: + item.url = host + 'movies/' + elif categoria == 'infantiles': + item.url = host + 'genre/animacion/' + elif categoria == 'terror': + item.url = host + 'genre/terror/' + item.type='movies' + itemlist = list_all(item) + if itemlist[-1].title == 'Siguiente >>': + itemlist.pop() + except: + import sys + for line in sys.exc_info(): + logger.error("{0}".format(line)) + return [] + + return itemlist diff --git a/plugin.video.alfa/channels/retroseriestv.json b/plugin.video.alfa/channels/retroseriestv.json new file mode 100644 index 00000000..cde2358b --- /dev/null +++ b/plugin.video.alfa/channels/retroseriestv.json @@ -0,0 +1,22 @@ +{ + "id": "retroseriestv", + "name": "RetroSeriesTV", + "active": true, + "adult": false, + "language": ["lat", "cast"], + "thumbnail": "https://retroseriestv.com/wp-content/uploads/2017/04/Logo3-5.png", + "banner": "", + "categories": [ + "tvshow" + ], + "settings": [ + { + "id": "include_in_global_search", + "type": "bool", + "label": "Incluir en busqueda global", + "default": false, + "enabled": false, + "visible": false + } + ] +} \ No newline at end of file diff --git a/plugin.video.alfa/channels/retroseriestv.py b/plugin.video.alfa/channels/retroseriestv.py new file mode 100644 index 00000000..2386b82f --- /dev/null +++ b/plugin.video.alfa/channels/retroseriestv.py @@ -0,0 +1,213 @@ +# -*- coding: utf-8 -*- +# -*- Channel RetroSeriesTV -*- +# -*- Created for Alfa-addon -*- +# -*- By the Alfa Develop Group -*- + +import re +import urllib +from channelselector import get_thumb +from core import httptools +from core import scrapertools +from core import servertools +from core import tmdb +from core.item import Item +from platformcode import config, logger +from channels import autoplay +from channels import filtertools + + +host = 'https://retroseriestv.com/' + +# IDIOMAS = {'la': 'LAT', 'es': 'Cast'} +# list_language = IDIOMAS.values() +# list_quality = [] +# list_servers = ['openload'] + + +def mainlist(item): + logger.info() + + itemlist = list() + itemlist.append(item.clone(title="Todas", action="list_all", url=host + 'seriestv/', thumbnail=get_thumb('all', + auto=True))) + + itemlist.append(item.clone(title="Generos", action="section", url=host, thumbnail=get_thumb('genres', auto=True), + section='genres')) + + itemlist.append(item.clone(title="Por Año", action="section", url=host, thumbnail=get_thumb('year', auto=True), + section='year')) + + itemlist.append(item.clone(title="Alfabetico", action="section", url=host, thumbnail=get_thumb('alphabet', auto=True), + section='abc')) + + itemlist.append(item.clone(title="Buscar", action="search", url=host+'?s=', + thumbnail=get_thumb('search', auto=True))) + + return itemlist + + +def get_source(url): + logger.info() + data = httptools.downloadpage(url).data + data = re.sub(r'"|\n|\r|\t| ||\s{2,}', "", data) + return data + +def list_all(item): + logger.info() + itemlist = [] + + data = get_source(item.url) + patron = '
- ' % item.section)
+ patron = '(.*?)'
+ matches = re.compile(patron, re.DOTALL).findall(data)
+
+ for scrapedurl, scrapedtitle in matches:
+ url = scrapedurl.strip()
+ itemlist.append(Item(channel=item.channel, title=scrapedtitle, url=url, action='list_all'))
+
+ return itemlist
+
+def seasons(item):
+ logger.info()
+
+ itemlist = []
+ data = get_source(item.url)
+ patron = 'Temporada(\d+) <'
+ matches = re.compile(patron, re.DOTALL).findall(data)
+
+ for scrapedtitle in matches:
+ infoLabels = item.infoLabels
+ infoLabels['season'] = scrapedtitle
+ title = 'Temporada %s' % scrapedtitle
+ itemlist.append(Item(channel=item.channel, title=title, url=item.url, action='episodesxseason',
+ infoLabels=infoLabels))
+ tmdb.set_infoLabels_itemlist(itemlist, seekTmdb=True)
+
+ if config.get_videolibrary_support() and len(itemlist) > 0:
+ itemlist.append(
+ Item(channel=item.channel, title='[COLOR yellow]Añadir esta serie a la videoteca[/COLOR]', url=item.url,
+ action="add_serie_to_library", extra="episodios", contentSerieName=item.contentSerieName,
+ extra1='library'))
+
+ return itemlist
+
+def episodios(item):
+ logger.info()
+ itemlist = []
+ templist = seasons(item)
+ for tempitem in templist:
+ itemlist += episodesxseason(tempitem)
+ return itemlist
+
+def episodesxseason(item):
+ logger.info()
+
+ itemlist = []
+
+ data = get_source(item.url)
+ infoLabels = item.infoLabels
+ season = infoLabels['season']
+ patron = '
1:
@@ -517,3 +581,90 @@ def get_saved_searches():
saved_searches_list = list(current_saved_searches_list)
return saved_searches_list
+
+
+def discover_list(item):
+ from platformcode import unify
+ itemlist = []
+
+ result = tmdb.discovery(item)
+
+ tvshow = False
+
+ logger.debug(item)
+
+ for elem in result:
+ elem['tmdb_id']=elem['id']
+ if 'title' in elem:
+ title = unify.normalize(elem['title']).capitalize()
+ elem['year'] = scrapertools.find_single_match(elem['release_date'], '(\d{4})-\d+-\d+')
+ else:
+ title = unify.normalize(elem['name']).capitalize()
+ tvshow = True
+
+ new_item = Item(channel='search', title=title, infoLabels=elem, action='search_tmdb', extra=title,
+ category='Resultados', context ='')
+
+ if tvshow:
+ new_item.contentSerieName = title
+ else:
+ new_item.contentTitle = title
+
+ itemlist.append(new_item)
+
+ tmdb.set_infoLabels_itemlist(itemlist, seekTmdb=True)
+
+ if item.page != '' and len(itemlist)>0:
+ next_page = str(int(item.page)+1)
+ #if not 'similar' in item.list_type:
+ # itemlist.append(item.clone(title='Pagina Siguente', page=next_page))
+ #else:
+ itemlist.append(Item(channel=item.channel, action='discover_list', title='Pagina Siguente',
+ search_type=item.search_type, list_type=item.list_type, type=item.type, page=next_page))
+
+ return itemlist
+
+def search_tmdb(item):
+ logger.debug(item)
+
+ itemlist = []
+ threads = []
+ logger.debug(item)
+ wanted = item.contentTitle
+
+ search = do_search(item)
+
+ if item.contentSerieName == '':
+ results = exact_results(search, wanted)
+ for result in results:
+ logger.debug(result)
+ t = Thread(target=get_links, args=[result])
+ t.start()
+ threads.append(t)
+
+ for thread in threads:
+ thread.join()
+
+ # try:
+ # get_links(result)
+ # except:
+ # pass
+
+ for link in link_list:
+ if link.action == 'play' and not 'trailer' in link.title.lower() and len(itemlist) < max_links:
+ itemlist.append(link)
+
+ return sorted(itemlist, key=lambda it: it.server)
+ else:
+ for item in search:
+ if item.contentSerieName != '' and item.contentSerieName == wanted:
+ logger.debug(item)
+ itemlist.append(item)
+ return itemlist
+
+def get_links (item):
+ logger.info()
+ results =[]
+ channel = __import__('channels.%s' % item.from_channel, None, None, ["channels.%s" % item.from_channel])
+ if len(link_list) <= max_links:
+ link_list.extend(getattr(channel, item.from_action)(item))
diff --git a/plugin.video.alfa/channels/seriesblanco.json b/plugin.video.alfa/channels/seriesblanco.json
old mode 100755
new mode 100644
index 1b326714..cab8afd1
--- a/plugin.video.alfa/channels/seriesblanco.json
+++ b/plugin.video.alfa/channels/seriesblanco.json
@@ -1,31 +1,22 @@
{
"id": "seriesblanco",
- "name": "Seriesblanco",
- "active": false,
+ "name": "SeriesBlanco",
+ "active": true,
"adult": false,
"language": ["cast", "lat"],
- "thumbnail": "seriesblanco.png",
- "banner": "seriesblanco.png",
+ "thumbnail": "https://s22.postimg.cc/nucz720sx/image.png",
+ "banner": "",
"categories": [
- "tvshow",
- "vos"
+ "tvshow"
],
"settings": [
{
"id": "include_in_global_search",
"type": "bool",
"label": "Incluir en busqueda global",
- "default": true,
- "enabled": true,
- "visible": true
- },
- {
- "id": "include_in_newest_series",
- "type": "bool",
- "label": "Incluir en Novedades - Episodios de series",
- "default": true,
- "enabled": true,
- "visible": true
+ "default": false,
+ "enabled": false,
+ "visible": false
},
{
"id": "filter_languages",
@@ -36,26 +27,10 @@
"visible": true,
"lvalues": [
"No filtrar",
- "Español",
- "Inglés",
- "Latino",
- "VO",
- "VOS",
- "VOSI",
- "OVOS"
- ]
- },
- {
- "id": "filterlinks",
- "type": "list",
- "label": "Mostrar enlaces de tipo...",
- "default": 2,
- "enabled": true,
- "visible": true,
- "lvalues": [
- "Solo Descarga",
- "Solo Online",
- "No filtrar"
+ "Cast",
+ "Lat",
+ "VOSE",
+ "VO"
]
}
]
diff --git a/plugin.video.alfa/channels/seriesblanco.py b/plugin.video.alfa/channels/seriesblanco.py
index 529d9fe1..d6a81de0 100644
--- a/plugin.video.alfa/channels/seriesblanco.py
+++ b/plugin.video.alfa/channels/seriesblanco.py
@@ -1,369 +1,353 @@
# -*- coding: utf-8 -*-
+# -*- Channel SeriesBlanco -*-
+# -*- Created for Alfa-addon -*-
+# -*- By the Alfa Develop Group -*-
import re
-import urlparse
+from channels import autoplay
from channels import filtertools
-from channelselector import get_thumb
from core import httptools
-from core import scrapertoolsV2
+from core import scrapertools
from core import servertools
+from core import tmdb
from core.item import Item
from platformcode import config, logger
-from core import tmdb
-from channels import autoplay
+from channelselector import get_thumb
+host = 'http://seriesblanco.xyz/'
-HOST = "https://seriesblanco.com/"
-IDIOMAS = {'es': 'Español', 'en': 'Inglés', 'la': 'Latino', 'vo': 'VO', 'vos': 'VOS', 'vosi': 'VOSI', 'otro': 'OVOS'}
-list_idiomas = IDIOMAS.values()
-list_language = ['default']
-CALIDADES = ['SD', 'HDiTunes', 'Micro-HD-720p', 'Micro-HD-1080p', '1080p', '720p']
-list_quality = CALIDADES
-
-list_servers = ['powvideo',
- 'streamcloud',
- 'openload',
- 'flashx',
- 'streamplay',
- 'nowvideo',
- 'gamovideo',
- 'kingvid',
- 'vidabc',
- 'streamixcloud'
- ]
+IDIOMAS = {'es': 'Cast', 'la': 'Lat', 'vos': 'VOSE', 'vo': 'VO'}
+list_language = IDIOMAS.values()
+list_quality = ['SD', 'Micro-HD-720p', '720p', 'HDitunes', 'Micro-HD-1080p' ]
+list_servers = ['powvideo','yourupload', 'openload', 'gamovideo', 'flashx', 'clipwatching', 'streamango', 'streamcloud']
def mainlist(item):
logger.info()
- thumb_series = get_thumb("channels_tvshow.png")
- thumb_series_az = get_thumb("channels_tvshow_az.png")
- thumb_buscar = get_thumb("search.png")
-
- itemlist = list()
-
autoplay.init(item.channel, list_servers, list_quality)
- itemlist.append(Item(channel=item.channel, title="Listado alfabético", action="series_listado_alfabetico",
- thumbnail=thumb_series_az))
- itemlist.append(Item(channel=item.channel, title="Todas las series", action="series",
- url=urlparse.urljoin(HOST, "listado/"), thumbnail=thumb_series))
- itemlist.append(
- Item(channel=item.channel, title="Capítulos estrenados recientemente", action="home_section",
- extra="Series Online : Capítulos estrenados recientemente",
- url=HOST, thumbnail=thumb_series))
- itemlist.append(Item(channel=item.channel, title="Series más vistas", action="series", extra="Series Más vistas",
- url=urlparse.urljoin(HOST, "listado-visto/"), thumbnail=thumb_series))
- itemlist.append(Item(channel=item.channel, title="Últimas fichas creadas", action="series",
- url=urlparse.urljoin(HOST, "fichas_creadas/"), thumbnail=thumb_series))
- itemlist.append(Item(channel=item.channel, title="Series por género", action="generos",
- url=HOST, thumbnail=thumb_series))
- itemlist.append(
- Item(channel=item.channel, title="Buscar...", action="search", url=urlparse.urljoin(HOST, "finder.php"),
- thumbnail=thumb_buscar))
- itemlist = filtertools.show_option(itemlist, item.channel, list_idiomas, CALIDADES)
+ itemlist = []
+ itemlist.append(Item(channel=item.channel,
+ title="Nuevos Capitulos",
+ action="new_episodes",
+ thumbnail=get_thumb('new_episodes', auto=True),
+ url=host))
+
+ itemlist.append(Item(channel=item.channel,
+ title="Todas",
+ action="list_all",
+ thumbnail=get_thumb('all', auto=True),
+ url=host + 'listado/',
+ ))
+
+ itemlist.append(Item(channel=item.channel,
+ title="Generos",
+ action="section",
+ thumbnail=get_thumb('genres', auto=True),
+ url=host,
+ ))
+
+ itemlist.append(Item(channel=item.channel,
+ title="A - Z",
+ action="section",
+ thumbnail=get_thumb('alphabet', auto=True),
+ url=host+'listado/', ))
+
+ itemlist.append(Item(channel=item.channel,
+ title="Buscar",
+ action="search",
+ thumbnail=get_thumb('search', auto=True)))
+
+ itemlist = filtertools.show_option(itemlist, item.channel, list_language, list_quality)
autoplay.show_option(item.channel, itemlist)
+
return itemlist
+def get_source(url):
+ logger.info()
+ data = httptools.downloadpage(url).data
+ data = re.sub(r'"|\n|\r|\t| ||\s{2,}', "", data) + return data -def home_section(item): - logger.info("section = %s" % item.extra) +def list_all(item): + logger.info() - pattern = "['\"]panel-title['\"]>[^/]*%s(.*?)(?:panel-title|\Z)" % item.extra - # logger.debug("pattern = %s" % pattern) - - data = httptools.downloadpage(item.url).data - result = re.search(pattern, data, re.MULTILINE | re.DOTALL) - - if result: - # logger.debug("found section: {0}".format(result.group(1))) - item.extra = 1 - return extract_series_from_data(item, result.group(1)) - - logger.debug("No match") - return [] - - -def extract_series_from_data(item, data): itemlist = [] - episode_pattern = re.compile('/capitulo-([0-9]+)/') - shows = re.findall("
|\s{2,}', "", data) + patron = ".*?src=(.*?) style.*?value=(.*?)>" + + matches = re.compile(patron, re.DOTALL).findall(data) + + for scrapedurl, scrapedthumb, scrapedtitle in matches: + itemlist.append(Item(channel=item.channel, + title=scrapedtitle, + url=host+scrapedurl, + action="seasons", + thumbnail=scrapedthumb, + contentSerieName=scrapedtitle, + context=filtertools.context(item, list_language, list_quality) + )) + tmdb.set_infoLabels_itemlist(itemlist, seekTmdb=True) + + return itemlist + +def search(item, texto): + logger.info() + import urllib + if texto != '': + post = {'query':texto} + post = urllib.urlencode(post) + item.post = post + + return search_results(item) diff --git a/plugin.video.alfa/channels/veseriesonline.py b/plugin.video.alfa/channels/veseriesonline.py index b1ba3b7b..0b9aeef0 100644 --- a/plugin.video.alfa/channels/veseriesonline.py +++ b/plugin.video.alfa/channels/veseriesonline.py @@ -183,50 +183,56 @@ def findvideos(item): # listado de opciones links_url - data = get_source(links_url) - patron = 'content >