fix il Genio dello Streaming
This commit is contained in:
@@ -174,4 +174,27 @@ def newest(categoria):
|
||||
|
||||
def findvideos(item):
|
||||
log()
|
||||
return support.server(item)
|
||||
matches = support.match(item, patron=[r'class="metaframe rptss" src="([^"]+)"',r' href="#option-\d">([^\s]+)\s*([^\s]+)']).matches
|
||||
itemlist = []
|
||||
list_url = []
|
||||
list_quality = []
|
||||
list_servers = []
|
||||
for match in matches:
|
||||
if type(match) == tuple:
|
||||
list_servers.append(match[0])
|
||||
list_quality.append(match[1])
|
||||
else:
|
||||
if 'player.php' in match:
|
||||
match = support.httptools.downloadpage(match, follow_redirect=True).url
|
||||
list_url.append(match)
|
||||
|
||||
for i, url in enumerate(list_url):
|
||||
itemlist.append(support.Item(
|
||||
channel=item.channel,
|
||||
title=list_servers[i],
|
||||
url=url,
|
||||
action='play',
|
||||
quality=list_quality[i],
|
||||
infoLabels = item.infoLabels))
|
||||
|
||||
return support.server(item, itemlist=itemlist)
|
||||
|
||||
@@ -228,7 +228,10 @@ def scrapeBlock(item, args, block, patron, headers, action, pagination, debug, t
|
||||
episode = ''
|
||||
else:
|
||||
episode = re.sub(r'\s-\s|-|x|–|×|×', 'x', scraped['episode']) if scraped['episode'] else ''
|
||||
second_episode = scrapertools.find_single_match(episode, 'x\d+x(\d+)')
|
||||
if 'x' in episode:
|
||||
ep = episode.split('x')
|
||||
episode = str(int(ep[0])).zfill(1) + 'x' + str(int(ep[1])).zfill(2)
|
||||
second_episode = scrapertools.find_single_match(episode, r'x\d+x(\d+)')
|
||||
if second_episode: episode = re.sub(r'(\d+x\d+)x\d+',r'\1-', episode) + second_episode.zfill(2)
|
||||
|
||||
#episode = re.sub(r'\s-\s|-|x|–|×', 'x', scraped['episode']) if scraped['episode'] else ''
|
||||
|
||||
Reference in New Issue
Block a user