Fix toonitalia (#276)
This commit is contained in:
+11
-13
@@ -5,17 +5,11 @@
|
|||||||
|
|
||||||
from core import support
|
from core import support
|
||||||
import sys
|
import sys
|
||||||
if sys.version_info[0] >= 3: from concurrent import futures
|
|
||||||
else: from concurrent_py2 import futures
|
|
||||||
|
|
||||||
host = support.config.get_channel_url()
|
host = support.config.get_channel_url()
|
||||||
|
|
||||||
headers = [['Referer', host]]
|
headers = [['Referer', host]]
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@support.menu
|
@support.menu
|
||||||
def mainlist(item):
|
def mainlist(item):
|
||||||
|
|
||||||
@@ -33,7 +27,7 @@ def search(item, text):
|
|||||||
support.info(text)
|
support.info(text)
|
||||||
# item.args='search'
|
# item.args='search'
|
||||||
item.text = text
|
item.text = text
|
||||||
item.url = item.url + '/?a=b&s=' + text.replace(' ', '+')
|
item.url = item.url + '/?%73=' + text.replace(' ', '+')
|
||||||
|
|
||||||
try:
|
try:
|
||||||
return peliculas(item)
|
return peliculas(item)
|
||||||
@@ -64,21 +58,25 @@ def newest(categoria):
|
|||||||
@support.scrape
|
@support.scrape
|
||||||
def peliculas(item):
|
def peliculas(item):
|
||||||
# debugBlock = True
|
# debugBlock = True
|
||||||
search = item.text
|
# debug = True
|
||||||
|
# search = item.text
|
||||||
if item.contentType != 'movie': anime = True
|
if item.contentType != 'movie': anime = True
|
||||||
action = 'findvideos' if item.contentType == 'movie' else 'episodios'
|
action = 'findvideos' if item.contentType == 'movie' else 'episodios'
|
||||||
blacklist = ['-Film Animazione disponibili in attesa di recensione ']
|
blacklist = ['-Film Animazione disponibili in attesa di recensione ']
|
||||||
|
|
||||||
if search:
|
if item.action == 'search':
|
||||||
pagination = ''
|
pagination = ''
|
||||||
patronBlock = '"lcp_catlist"[^>]+>(?P<block>.*)</ul>'
|
#patronBlock = '"lcp_catlist"[^>]+>(?P<block>.*)</ul>'
|
||||||
patron = r'href="(?P<url>[^"]+)" title="(?P<title>[^"]+)"'
|
patronBlock = '<main[^>]+>(?P<block>.*?)</ma'
|
||||||
|
#patron = r'href="(?P<url>[^"]+)" title="(?P<title>[^"]+)"'
|
||||||
|
patron = r'<a href="(?P<url>[^"]+)"[^>]*>(?P<title>[^<]+)<[^>]+>[^>]+><div'
|
||||||
elif item.args == 'last':
|
elif item.args == 'last':
|
||||||
patronBlock = 'Aggiornamenti</h2>(?P<block>.*)</ul>'
|
patronBlock = 'Aggiornamenti</h2>(?P<block>.*)</ul>'
|
||||||
patron = r'<a href="(?P<url>[^"]+)">\s*<img[^>]+src(?:set)?="(?P<thumbnail>[^ ]+)[^>]+>\s*<span[^>]+>(?P<title>[^<]+)'
|
patron = r'<a href="(?P<url>[^"]+)">\s*<img[^>]+src[set]{0,3}="(?P<thumbnail>[^ ]+)[^>]+>\s*<span[^>]+>(?P<title>[^<]+)'
|
||||||
else:
|
else:
|
||||||
patronBlock = '<main[^>]+>(?P<block>.*)</main>'
|
patronBlock = '<main[^>]+>(?P<block>.*)</main>'
|
||||||
patron = r'<a href="(?P<url>[^"]+)" rel="bookmark">(?P<title>[^<]+)</a>[^>]+>[^>]+>[^>]+><img.*?src="(?P<thumb>[^"]+)".*?<p>(?P<plot>[^<]+)</p>.*?<span class="cat-links">Pubblicato in.*?.*?(?P<type>(?:[Ff]ilm|</artic))[^>]+>'
|
# patron = r'<a href="(?P<url>[^"]+)" rel="bookmark">(?P<title>[^<]+)</a>[^>]+>[^>]+>[^>]+><img.*?src="(?P<thumb>[^"]+)".*?<p>(?P<plot>[^<]+)</p>.*?<span class="cat-links">Pubblicato in.*?.*?(?P<type>(?:[Ff]ilm|</artic))[^>]+>'
|
||||||
|
patron = r'<a href="(?P<url>[^"]+)"[^>]+>(?P<title>[^<]+)</a>[^>]+>[^>]+>[^>]+><img.*?src="(?P<thumb>[^"]+)".*?<p>(?P<plot>[^<]+)</p>.*?tag">.*?(?P<type>(?:[Ff]ilm|</art|Serie Tv))'
|
||||||
typeContentDict={'movie':['film']}
|
typeContentDict={'movie':['film']}
|
||||||
typeActionDict={'findvideos':['film']}
|
typeActionDict={'findvideos':['film']}
|
||||||
patronNext = '<a class="next page-numbers" href="([^"]+)">'
|
patronNext = '<a class="next page-numbers" href="([^"]+)">'
|
||||||
|
|||||||
Reference in New Issue
Block a user