pulizia
This commit is contained in:
@@ -48,7 +48,7 @@ from core import support
|
||||
from platformcode import config
|
||||
|
||||
# in caso di necessità
|
||||
#from core import scrapertoolsV2, httptools, servertools, tmdb
|
||||
#from core import scrapertools, httptools, servertools, tmdb
|
||||
from core.item import Item # per newest
|
||||
#from lib import unshortenit
|
||||
|
||||
@@ -74,7 +74,7 @@ def findhost():
|
||||
permUrl = httptools.downloadpage('INSERIRE-URL-QUI', follow_redirects=False).headers
|
||||
host = 'https://www.'+permUrl['location'].replace('https://www.google.it/search?q=site:', '')
|
||||
# cancellare host non utilizzato
|
||||
host = scrapertoolsV2.find_single_match(permUrl, r'<div class="elementor-button-wrapper"> <a href="([^"]+)"')
|
||||
host = scrapertools.find_single_match(permUrl, r'<div class="elementor-button-wrapper"> <a href="([^"]+)"')
|
||||
headers = [['Referer', host]]
|
||||
# così le imposta una volta per tutte
|
||||
### fine findhost
|
||||
@@ -220,7 +220,7 @@ def select(item):
|
||||
# pulizia di data, in caso commentare le prossime 2 righe
|
||||
data = re.sub('\n|\t', ' ', data)
|
||||
data = re.sub(r'>\s+<', '> <', data)
|
||||
block = scrapertoolsV2.find_single_match(data, r'')
|
||||
block = scrapertools.find_single_match(data, r'')
|
||||
if re.findall('', data, re.IGNORECASE):
|
||||
support.log('select = ### è una serie ###')
|
||||
return episodios(Item(channel=item.channel,
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
Ulteriori info:
|
||||
|
||||
"""
|
||||
from core import scrapertoolsV2, httptools, support
|
||||
from core import scrapertools, httptools, support
|
||||
from core.item import Item
|
||||
from platformcode import config, logger
|
||||
|
||||
@@ -21,7 +21,7 @@ from platformcode import config, logger
|
||||
|
||||
def findhost():
|
||||
data = httptools.downloadpage('https://altadefinizione01-nuovo.link/').data
|
||||
host = scrapertoolsV2.find_single_match(data, '<div class="elementor-button-wrapper"> <a href="([^"]+)"')
|
||||
host = scrapertools.find_single_match(data, '<div class="elementor-button-wrapper"> <a href="([^"]+)"')
|
||||
return host
|
||||
|
||||
|
||||
|
||||
@@ -81,8 +81,8 @@ def peliculas(item):
|
||||
if item.args == 'newest':
|
||||
url = support.match(item, '<a href="([^"]+)" title="[^"]+" target="[^"]+" class="btn', headers=headers)[0]
|
||||
item.url = url[0] if url else ''
|
||||
delete = support.scrapertoolsV2.find_single_match(item.fulltitle, r'( Episodi.*)')
|
||||
episode = support.scrapertoolsV2.find_single_match(item.title, r'Episodi(?:o)? (?:\d+÷)?(\d+)')
|
||||
delete = support.scrapertools.find_single_match(item.fulltitle, r'( Episodi.*)')
|
||||
episode = support.scrapertools.find_single_match(item.title, r'Episodi(?:o)? (?:\d+÷)?(\d+)')
|
||||
item.title = support.typo(episode + ' - ','bold') + item.title.replace(delete,'')
|
||||
item.fulltitle = item.show = item.title.replace(delete,'')
|
||||
item.episode = episode
|
||||
|
||||
@@ -118,8 +118,8 @@ def findvideos(item):
|
||||
headers['Referer'] = item.url
|
||||
headers['Cookie'] = cookies[:-1]
|
||||
|
||||
url = support.scrapertoolsV2.find_single_match(data, """<source src="([^"]+)" type='video/mp4'>""")
|
||||
if not url: url = support.scrapertoolsV2.find_single_match(data, 'file: "([^"]+)"')
|
||||
url = support.scrapertools.find_single_match(data, """<source src="([^"]+)" type='video/mp4'>""")
|
||||
if not url: url = support.scrapertools.find_single_match(data, 'file: "([^"]+)"')
|
||||
if url:
|
||||
url += '|' + urllib.urlencode(headers)
|
||||
itemlist.append(
|
||||
|
||||
@@ -145,9 +145,9 @@ def findvideos(item):
|
||||
videoData = ''
|
||||
|
||||
for serverid in matches:
|
||||
if not item.number: item.number = support.scrapertoolsV2.find_single_match(item.title,r'(\d+) -')
|
||||
block = support.scrapertoolsV2.find_multiple_matches(data,'data-id="' + serverid + '">(.*?)<div class="server')
|
||||
ID = support.scrapertoolsV2.find_single_match(str(block),r'<a data-id="([^"]+)" data-base="' + (item.number if item.number else '1') + '"')
|
||||
if not item.number: item.number = support.scrapertools.find_single_match(item.title, r'(\d+) -')
|
||||
block = support.scrapertools.find_multiple_matches(data, 'data-id="' + serverid + '">(.*?)<div class="server')
|
||||
ID = support.scrapertools.find_single_match(str(block), r'<a data-id="([^"]+)" data-base="' + (item.number if item.number else '1') + '"')
|
||||
support.log('ID= ',serverid)
|
||||
if id:
|
||||
if serverid == '26':
|
||||
|
||||
@@ -24,7 +24,7 @@ from core import support
|
||||
from platformcode import config
|
||||
|
||||
# in caso di necessità
|
||||
from core import scrapertoolsV2, httptools
|
||||
from core import scrapertools, httptools
|
||||
from core.item import Item
|
||||
|
||||
|
||||
@@ -124,7 +124,7 @@ def select(item):
|
||||
data = re.sub('\n|\t', ' ', data)
|
||||
data = re.sub(r'>\s+<', '> <', data)
|
||||
if 'continua con il video' in data.lower():
|
||||
## block = scrapertoolsV2.find_single_match(data, r'<div class="col-md-8 bg-white rounded-left p-5"><div>(.*?)<div style="margin-left: 0.5%; color: #FFF;">')
|
||||
## block = scrapertools.find_single_match(data, r'<div class="col-md-8 bg-white rounded-left p-5"><div>(.*?)<div style="margin-left: 0.5%; color: #FFF;">')
|
||||
## if re.findall('rel="category tag">serie', data, re.IGNORECASE):
|
||||
support.log('select = ### è un film ###')
|
||||
return findvideos(Item(channel=item.channel,
|
||||
|
||||
@@ -19,13 +19,13 @@
|
||||
"""
|
||||
|
||||
from core import support
|
||||
from core import scrapertoolsV2, httptools
|
||||
from core import scrapertools, httptools
|
||||
from core.item import Item
|
||||
|
||||
|
||||
def findhost():
|
||||
data = httptools.downloadpage('https://casacinema.nuovo.link').data
|
||||
host = scrapertoolsV2.find_single_match(data, r'<div class="elementor-widget-container"><div class="elementor-button-wrapper"> <a href="([^"]+)"')
|
||||
host = scrapertools.find_single_match(data, r'<div class="elementor-widget-container"><div class="elementor-button-wrapper"> <a href="([^"]+)"')
|
||||
if host.endswith('/'):
|
||||
host = host[:-1]
|
||||
return host
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
|
||||
import re
|
||||
|
||||
from core import scrapertoolsV2, httptools, servertools, tmdb, support
|
||||
from core import scrapertools, httptools, servertools, tmdb, support
|
||||
from core.item import Item
|
||||
from lib import unshortenit
|
||||
from platformcode import logger, config
|
||||
@@ -173,7 +173,7 @@ def findvideos(item):
|
||||
return findvid_serie(item)
|
||||
|
||||
def load_links(itemlist, re_txt, color, desc_txt, quality=""):
|
||||
streaming = scrapertoolsV2.find_single_match(data, re_txt).replace('"', '')
|
||||
streaming = scrapertools.find_single_match(data, re_txt).replace('"', '')
|
||||
support.log('STREAMING',streaming)
|
||||
support.log('STREAMING=', streaming)
|
||||
# patron = '<td><a.*?href=(.*?) (?:target|rel)[^>]+>([^<]+)<'
|
||||
@@ -207,7 +207,7 @@ def findvideos(item):
|
||||
matches = re.compile(patronvideos, re.DOTALL).finditer(data)
|
||||
QualityStr = ""
|
||||
for match in matches:
|
||||
QualityStr = scrapertoolsV2.decodeHtmlentities(match.group(1))[6:]
|
||||
QualityStr = scrapertools.decodeHtmlentities(match.group(1))[6:]
|
||||
|
||||
# Estrae i contenuti - Streaming
|
||||
load_links(itemlist, '<strong>Streamin?g:</strong>(.*?)cbtable', "orange", "Streaming", "SD")
|
||||
@@ -307,12 +307,12 @@ def play(item):
|
||||
data = httptools.downloadpage(item.url).data
|
||||
if "window.location.href" in data:
|
||||
try:
|
||||
data = scrapertoolsV2.find_single_match(data, 'window.location.href = "([^"]+)";')
|
||||
data = scrapertools.find_single_match(data, 'window.location.href = "([^"]+)";')
|
||||
except IndexError:
|
||||
data = httptools.downloadpage(item.url, only_headers=True, follow_redirects=False).headers.get("location", "")
|
||||
data, c = unshortenit.unwrap_30x_only(data)
|
||||
else:
|
||||
data = scrapertoolsV2.find_single_match(data, r'<a href="([^"]+)".*?class="btn-wrapper">.*?licca.*?</a>')
|
||||
data = scrapertools.find_single_match(data, r'<a href="([^"]+)".*?class="btn-wrapper">.*?licca.*?</a>')
|
||||
|
||||
logger.debug("##### play go.php data ##\n%s\n##" % data)
|
||||
else:
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
|
||||
import re
|
||||
|
||||
from core import httptools, support, scrapertoolsV2
|
||||
from core import httptools, support, scrapertools
|
||||
from core.item import Item
|
||||
from platformcode import config
|
||||
|
||||
@@ -89,7 +89,7 @@ def episodios(item):
|
||||
patronBlock = r'<p><strong>(?:.+?[Ss]tagione\s)?(?:(?P<lang>iTA|ITA|Sub-ITA|Sub-iTA))?.*?</strong>(?P<block>.+?)(?:</span|</p)'
|
||||
item.contentType = 'tvshow'
|
||||
def itemHook(item):
|
||||
if not scrapertoolsV2.find_single_match(item.title, r'(\d+x\d+)'):
|
||||
if not scrapertools.find_single_match(item.title, r'(\d+x\d+)'):
|
||||
item.title = re.sub(r'(\d+) -', '1x\\1', item.title)
|
||||
return item
|
||||
|
||||
@@ -148,7 +148,7 @@ def check(item):
|
||||
support.log()
|
||||
data = httptools.downloadpage(item.url, headers=headers).data
|
||||
if data:
|
||||
blockAnime = scrapertoolsV2.find_single_match(data, r'<div id="container" class="container">(.+?<div style="margin-left)')
|
||||
blockAnime = scrapertools.find_single_match(data, r'<div id="container" class="container">(.+?<div style="margin-left)')
|
||||
|
||||
if blockAnime and ('episodio' in blockAnime.lower() or 'saga' in blockAnime.lower()):
|
||||
item.contentType = 'tvshow'
|
||||
@@ -156,7 +156,7 @@ def check(item):
|
||||
item.data = blockAnime
|
||||
return episodios(item)
|
||||
|
||||
elif scrapertoolsV2.find_single_match(blockAnime,r'\d+(?:×|×)?\d+\-\d+|\d+(?:×|×)\d+'):
|
||||
elif scrapertools.find_single_match(blockAnime, r'\d+(?:×|×)?\d+\-\d+|\d+(?:×|×)\d+'):
|
||||
item.contentType = 'tvshow'
|
||||
item.data = data
|
||||
return episodios(item)
|
||||
|
||||
@@ -47,7 +47,7 @@ import re
|
||||
|
||||
from core import support
|
||||
from platformcode import config
|
||||
from core import scrapertoolsV2, httptools, servertools, tmdb
|
||||
from core import scrapertools, httptools, servertools, tmdb
|
||||
from core.item import Item
|
||||
|
||||
##### fine import
|
||||
@@ -228,8 +228,8 @@ def findvideos(item):
|
||||
data = re.sub(r'>\s\s*<', '><', data)
|
||||
patronBlock = r'LINK STREAMING(?P<block>.*?)LINK DOWNLOAD'
|
||||
patron = r'href="(.+?)"'
|
||||
block = scrapertoolsV2.find_single_match(data, patronBlock)
|
||||
urls = scrapertoolsV2.find_multiple_matches(block, patron)
|
||||
block = scrapertools.find_single_match(data, patronBlock)
|
||||
urls = scrapertools.find_multiple_matches(block, patron)
|
||||
#support.regexDbg(item, patron, headers, data=data)
|
||||
|
||||
for url in urls:
|
||||
@@ -241,7 +241,7 @@ def findvideos(item):
|
||||
lang = 'ITA'
|
||||
|
||||
if 'keepem.online' in data:
|
||||
urls = scrapertoolsV2.find_multiple_matches(data, r'(https://keepem\.online/f/[^"]+)"')
|
||||
urls = scrapertools.find_multiple_matches(data, r'(https://keepem\.online/f/[^"]+)"')
|
||||
for url in urls:
|
||||
url = httptools.downloadpage(url).url
|
||||
itemlist += servertools.find_video_items(data=url)
|
||||
@@ -254,14 +254,14 @@ def findvideos(item):
|
||||
|
||||
data = httptools.downloadpage(data).data
|
||||
support.log("LINK-DATA2 :", data)
|
||||
video_urls = scrapertoolsV2.find_single_match(data, r'<meta name="description" content="([^"]+)"')
|
||||
video_urls = scrapertools.find_single_match(data, r'<meta name="description" content="([^"]+)"')
|
||||
|
||||
else:
|
||||
|
||||
data = httptools.downloadpage(url).data
|
||||
#host_video = scrapertoolsV2.find_single_match(data, r'var thisPageUrl = "(http[s]\:\/\/[^\/]+).+?"')
|
||||
host_video = scrapertoolsV2.find_single_match(data, r'(?:let|var) thisPageUrl = "(http[s]\:\/\/[^\/]+).+?"')
|
||||
link = scrapertoolsV2.find_single_match(data, r'<video src="([^"]+)"')
|
||||
#host_video = scrapertools.find_single_match(data, r'var thisPageUrl = "(http[s]\:\/\/[^\/]+).+?"')
|
||||
host_video = scrapertools.find_single_match(data, r'(?:let|var) thisPageUrl = "(http[s]\:\/\/[^\/]+).+?"')
|
||||
link = scrapertools.find_single_match(data, r'<video src="([^"]+)"')
|
||||
video_urls = host_video+link
|
||||
|
||||
title_show = support.typo(titles,'_ bold') + support.typo(lang,'_ [] color kod')
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
- serie, anime
|
||||
"""
|
||||
import re
|
||||
from core import scrapertoolsV2, httptools, support
|
||||
from core import scrapertools, httptools, support
|
||||
from core.item import Item
|
||||
from platformcode import config
|
||||
|
||||
@@ -96,13 +96,13 @@ def pagina(url):
|
||||
data = httptools.downloadpage(url, headers=headers).data.replace("'", '"')
|
||||
#support.log("DATA ----###----> ", data)
|
||||
if 'clicca qui per aprire' in data.lower():
|
||||
url = scrapertoolsV2.find_single_match(data, '"go_to":"([^"]+)"')
|
||||
url = scrapertools.find_single_match(data, '"go_to":"([^"]+)"')
|
||||
url = url.replace("\\","")
|
||||
# Carica la pagina
|
||||
data = httptools.downloadpage(url, headers=headers).data.replace("'", '"')
|
||||
|
||||
elif 'clicca qui</span>' in data.lower():
|
||||
url = scrapertoolsV2.find_single_match(data, '<h2 style="text-align: center;"><a href="([^"]+)">')
|
||||
url = scrapertools.find_single_match(data, '<h2 style="text-align: center;"><a href="([^"]+)">')
|
||||
# Carica la pagina
|
||||
data = httptools.downloadpage(url, headers=headers).data.replace("'", '"')
|
||||
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
- SOLO SUB-ITA
|
||||
|
||||
"""
|
||||
from core import support, httptools, scrapertoolsV2
|
||||
from core import support, httptools, scrapertools
|
||||
from core.item import Item
|
||||
from core.support import log
|
||||
from platformcode import config
|
||||
@@ -158,7 +158,7 @@ def findvideos(item):
|
||||
|
||||
data = httptools.downloadpage(item.url).data
|
||||
patron = r'>Posted in <a href="https?://fastsubita.com/serietv/([^/]+)/(?:[^"]+)?"'
|
||||
series = scrapertoolsV2.find_single_match(data, patron)
|
||||
series = scrapertools.find_single_match(data, patron)
|
||||
titles = support.typo(series.upper().replace('-', ' '), 'bold color kod')
|
||||
goseries = support.typo("Vai alla Serie:", ' bold color kod')
|
||||
itemlist.append(
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
"""
|
||||
import re
|
||||
|
||||
from core import scrapertoolsV2, httptools, support
|
||||
from core import scrapertools, httptools, support
|
||||
from core.item import Item
|
||||
from platformcode import config
|
||||
|
||||
@@ -113,7 +113,7 @@ def select(item):
|
||||
support.log()
|
||||
|
||||
data = httptools.downloadpage(item.url, headers=headers).data
|
||||
patronBlock = scrapertoolsV2.find_single_match(data, r'class="taxonomy category" ><span property="name">(.*?)</span></a><meta property="position" content="2">')
|
||||
patronBlock = scrapertools.find_single_match(data, r'class="taxonomy category" ><span property="name">(.*?)</span></a><meta property="position" content="2">')
|
||||
if patronBlock.lower() != 'film':
|
||||
support.log('select = ### è una serie ###')
|
||||
item.contentType='tvshow'
|
||||
|
||||
@@ -1,37 +0,0 @@
|
||||
{
|
||||
"id": "hdblog",
|
||||
"name": "Hdblog",
|
||||
"language": ["ita"],
|
||||
"active": true,
|
||||
"adult": false,
|
||||
"thumbnail": "http://css.hd-cdn.it/new_files/templates/theme_darklight/img/logos_wt/logohdhardware.png",
|
||||
"banner": "http://css.hd-cdn.it/new_files/templates/theme_darklight/img/logos_wt/logohdhardware.png",
|
||||
"categories": ["documentary"],
|
||||
"settings": [
|
||||
{
|
||||
"id": "include_in_global_search",
|
||||
"type": "bool",
|
||||
"label": "Includi in Ricerca Globale",
|
||||
"default": false,
|
||||
"enabled": false,
|
||||
"visible": false
|
||||
},
|
||||
{
|
||||
"id": "include_in_newest_documentales",
|
||||
"type": "bool",
|
||||
"label": "Includi in Novità - Documentari",
|
||||
"default": true,
|
||||
"enabled": true,
|
||||
"visible": true
|
||||
},
|
||||
{
|
||||
"id": "include_in_newest_italiano",
|
||||
"type": "bool",
|
||||
"label": "Includi in Novità - Italiano",
|
||||
"default": true,
|
||||
"enabled": true,
|
||||
"visible": true
|
||||
}
|
||||
]
|
||||
}
|
||||
|
||||
@@ -1,94 +0,0 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# ------------------------------------------------------------
|
||||
# Ringraziamo Icarus crew
|
||||
# Canale hdblog
|
||||
# ------------------------------------------------------------
|
||||
import re
|
||||
import urlparse
|
||||
|
||||
from core import httptools, scrapertools
|
||||
from core.item import Item
|
||||
from platformcode import logger
|
||||
from platformcode import config
|
||||
|
||||
host = "https://www.hdblog.it"
|
||||
|
||||
|
||||
def mainlist(item):
|
||||
logger.info("kod.hdblog mainlist")
|
||||
itemlist = [Item(channel=item.channel,
|
||||
title="[COLOR azure]Video recensioni tecnologiche[/COLOR]",
|
||||
action="peliculas",
|
||||
url=host + "/video/",
|
||||
thumbnail="http://www.crat-arct.org/uploads/images/tic%201.jpg"),
|
||||
Item(channel=item.channel,
|
||||
title="[COLOR azure]Categorie[/COLOR]",
|
||||
action="categorias",
|
||||
url=host + "/video/",
|
||||
thumbnail="http://www.crat-arct.org/uploads/images/tic%201.jpg")]
|
||||
|
||||
return itemlist
|
||||
|
||||
|
||||
def categorias(item):
|
||||
logger.info("kod.hdblog categorias")
|
||||
itemlist = []
|
||||
|
||||
data = httptools.downloadpage(item.url).data
|
||||
logger.info(data)
|
||||
|
||||
# Narrow search by selecting only the combo
|
||||
start = data.find('<section class="left_toolbar" style="float: left;width: 125px;margin-right: 18px;">')
|
||||
end = data.find('</section>', start)
|
||||
bloque = data[start:end]
|
||||
|
||||
# The categories are the options for the combo
|
||||
patron = '<a href="([^"]+)"[^>]+><span>(.*?)</span>'
|
||||
matches = re.compile(patron, re.DOTALL).findall(bloque)
|
||||
scrapertools.printMatches(matches)
|
||||
|
||||
for scrapedurl, scrapedtitle in matches:
|
||||
scrapedthumbnail = ""
|
||||
scrapedplot = ""
|
||||
itemlist.append(
|
||||
Item(channel=item.channel,
|
||||
action="peliculas",
|
||||
title="[COLOR azure]" + scrapedtitle + "[/COLOR]",
|
||||
url=scrapedurl + "video/",
|
||||
thumbnail=scrapedthumbnail,
|
||||
plot=scrapedplot))
|
||||
|
||||
return itemlist
|
||||
|
||||
|
||||
def peliculas(item):
|
||||
logger.info("kod.hdblog peliculas")
|
||||
itemlist = []
|
||||
|
||||
# Carica la pagina
|
||||
data = httptools.downloadpage(item.url).data
|
||||
|
||||
# Estrae i contenuti
|
||||
patron = '<a class="thumb_new_image" href="([^"]+)">\s*<img[^s]+src="([^"]+)"[^>]+>\s*</a>\s*[^>]+>\s*(.*?)\s*<'
|
||||
matches = re.compile(patron, re.DOTALL).findall(data)
|
||||
scrapertools.printMatches(matches)
|
||||
|
||||
for scrapedurl, scrapedthumbnail, scrapedtitle in matches:
|
||||
scrapedtitle = scrapertools.decodeHtmlentities(scrapedtitle)
|
||||
scrapedplot = ""
|
||||
itemlist.append(Item(channel=item.channel, action="findvideos", fulltitle=scrapedtitle, show=scrapedtitle,
|
||||
title=scrapedtitle, url=scrapedurl, thumbnail=scrapedthumbnail, plot=scrapedplot,
|
||||
folder=True))
|
||||
|
||||
# Paginazione
|
||||
patronvideos = '<span class="attiva">[^>]+>[^=]+="next" href="(.*?)" class="inattiva">'
|
||||
matches = re.compile(patronvideos, re.DOTALL).findall(data)
|
||||
scrapertools.printMatches(matches)
|
||||
|
||||
if len(matches) > 0:
|
||||
scrapedurl = urlparse.urljoin(item.url, matches[0])
|
||||
itemlist.append(
|
||||
Item(channel=item.channel, action="peliculas", title="[COLOR orange]Avanti >>[/COLOR]", url=scrapedurl,
|
||||
folder=True))
|
||||
|
||||
return itemlist
|
||||
@@ -33,7 +33,7 @@
|
||||
|
||||
import re
|
||||
|
||||
from core import scrapertoolsV2, httptools, support
|
||||
from core import scrapertools, httptools, support
|
||||
from core.support import log
|
||||
from core.item import Item
|
||||
from platformcode import config
|
||||
@@ -216,7 +216,7 @@ def findvideos(item):
|
||||
matches, data = support.match(item, '<iframe class="metaframe rptss" src="([^"]+)"[^>]+>',headers=headers)
|
||||
for url in matches:
|
||||
html = httptools.downloadpage(url, headers=headers).data
|
||||
data += str(scrapertoolsV2.find_multiple_matches(html, '<meta name="og:url" content="([^"]+)">'))
|
||||
data += str(scrapertools.find_multiple_matches(html, '<meta name="og:url" content="([^"]+)">'))
|
||||
|
||||
itemlist = support.server(item, data)
|
||||
|
||||
@@ -224,7 +224,7 @@ def findvideos(item):
|
||||
|
||||
data = httptools.downloadpage(item.url).data
|
||||
patron = r'<div class="item"><a href="'+host+'/serietv/([^"\/]+)\/"><i class="icon-bars">'
|
||||
series = scrapertoolsV2.find_single_match(data, patron)
|
||||
series = scrapertools.find_single_match(data, patron)
|
||||
titles = support.typo(series.upper().replace('-', ' '), 'bold color kod')
|
||||
goseries = support.typo("Vai alla Serie:", ' bold')
|
||||
itemlist.append(
|
||||
|
||||
@@ -1,37 +0,0 @@
|
||||
{
|
||||
"id": "ilgiramondo",
|
||||
"name": "IlGiramondo",
|
||||
"language": ["ita"],
|
||||
"active": true,
|
||||
"adult": false,
|
||||
"thumbnail": "http://www.ilgiramondo.net/wp-content/uploads/2013/05/logo-fixed.jpg",
|
||||
"banner": "http://www.ilgiramondo.net/wp-content/uploads/2013/05/logo-fixed.jpg",
|
||||
"categories": ["documentary"],
|
||||
"settings": [
|
||||
{
|
||||
"id": "include_in_global_search",
|
||||
"type": "bool",
|
||||
"label": "Incluir en busqueda global",
|
||||
"default": false,
|
||||
"enabled": false,
|
||||
"visible": false
|
||||
},
|
||||
{
|
||||
"id": "include_in_newest_documentales",
|
||||
"type": "bool",
|
||||
"label": "Includi in Novità - Documentari",
|
||||
"default": true,
|
||||
"enabled": true,
|
||||
"visible": true
|
||||
},
|
||||
{
|
||||
"id": "include_in_newest_italiano",
|
||||
"type": "bool",
|
||||
"label": "Includi in Novità - Italiano",
|
||||
"default": true,
|
||||
"enabled": true,
|
||||
"visible": true
|
||||
}
|
||||
]
|
||||
}
|
||||
|
||||
@@ -1,67 +0,0 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# ------------------------------------------------------------
|
||||
# Ringraziamo Icarus crew
|
||||
# Canale ilgiramondo
|
||||
# ------------------------------------------------------------
|
||||
import re
|
||||
import urlparse
|
||||
|
||||
from core import httptools, scrapertools
|
||||
from core.item import Item
|
||||
from platformcode import logger
|
||||
from platformcode import config
|
||||
|
||||
host = "http://www.ilgiramondo.net"
|
||||
|
||||
|
||||
def mainlist(item):
|
||||
logger.info("kod.ilgiramondo mainlist")
|
||||
itemlist = [Item(channel=item.channel, title="[COLOR azure]Video di Viaggi[/COLOR]", action="peliculas",
|
||||
url=host + "/video-vacanze-viaggi/",
|
||||
thumbnail="http://hotelsjaisalmer.com/wp-content/uploads/2016/10/Travel1.jpg")]
|
||||
|
||||
return itemlist
|
||||
|
||||
|
||||
def peliculas(item):
|
||||
logger.info("kod.ilgiramondo peliculas")
|
||||
itemlist = []
|
||||
|
||||
# Carica la pagina
|
||||
data = httptools.downloadpage(item.url).data
|
||||
|
||||
# Estrae i contenuti
|
||||
patron = '<article id=[^>]+><div class="space">\s*<a href="([^"]+)"><img[^s]+src="(.*?)"[^>]+><\/a>'
|
||||
matches = re.compile(patron, re.DOTALL).findall(data)
|
||||
scrapertools.printMatches(matches)
|
||||
|
||||
for scrapedurl, scrapedthumbnail in matches:
|
||||
html = httptools.downloadpage(scrapedurl).data
|
||||
start = html.find("</script></div>")
|
||||
end = html.find("</p>", start)
|
||||
scrapedplot = html[start:end]
|
||||
scrapedplot = re.sub(r'<[^>]*>', '', scrapedplot)
|
||||
scrapedplot = scrapertools.decodeHtmlentities(scrapedplot)
|
||||
html = httptools.downloadpage(scrapedurl).data
|
||||
start = html.find("<title>")
|
||||
end = html.find("</title>", start)
|
||||
scrapedtitle = html[start:end]
|
||||
scrapedtitle = re.sub(r'<[^>]*>', '', scrapedtitle)
|
||||
scrapedtitle = scrapedtitle.replace(" | Video Di Viaggi E Vacanze", "")
|
||||
# scrapedplot = ""
|
||||
itemlist.append(Item(channel=item.channel, action="findvideos", fulltitle=scrapedtitle, show=scrapedtitle,
|
||||
title=scrapedtitle, url=scrapedurl, thumbnail=scrapedthumbnail, plot=scrapedplot,
|
||||
folder=True))
|
||||
|
||||
# Paginazione
|
||||
patronvideos = '<a class="next page-numbers" href="(.*?)">Successivo'
|
||||
matches = re.compile(patronvideos, re.DOTALL).findall(data)
|
||||
scrapertools.printMatches(matches)
|
||||
|
||||
if len(matches) > 0:
|
||||
scrapedurl = urlparse.urljoin(item.url, matches[0])
|
||||
itemlist.append(
|
||||
Item(channel=item.channel, action="peliculas", title="[COLOR orange]Avanti >>[/COLOR]", url=scrapedurl,
|
||||
folder=True))
|
||||
|
||||
return itemlist
|
||||
@@ -1,37 +0,0 @@
|
||||
{
|
||||
"id": "istitutoluce",
|
||||
"name": "Istituto Luce",
|
||||
"language": ["ita"],
|
||||
"active": true,
|
||||
"adult": false,
|
||||
"thumbnail": "http://www.archivioluce.com/wp-content/themes/wpbootstrap/bootstrap/img/luce-logo.png",
|
||||
"banner": "http://www.archivioluce.com/wp-content/themes/wpbootstrap/bootstrap/img/luce-logo.png",
|
||||
"categories": ["documentary"],
|
||||
"settings": [
|
||||
{
|
||||
"id": "include_in_global_search",
|
||||
"type": "bool",
|
||||
"label": "Includi in Ricerca Globale",
|
||||
"default": false,
|
||||
"enabled": false,
|
||||
"visible": false
|
||||
},
|
||||
{
|
||||
"id": "include_in_newest_documentales",
|
||||
"type": "bool",
|
||||
"label": "Includi in Novità - Documentari",
|
||||
"default": true,
|
||||
"enabled": true,
|
||||
"visible": true
|
||||
},
|
||||
{
|
||||
"id": "include_in_newest_italiano",
|
||||
"type": "bool",
|
||||
"label": "Includi in Novità - Italiano",
|
||||
"default": true,
|
||||
"enabled": true,
|
||||
"visible": true
|
||||
}
|
||||
]
|
||||
}
|
||||
|
||||
@@ -1,288 +0,0 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# ------------------------------------------------------------
|
||||
# Ringraziamo Icarus crew
|
||||
# Canale istitutoluce
|
||||
# ------------------------------------------------------------
|
||||
|
||||
import re
|
||||
import urlparse
|
||||
|
||||
from core import httptools, scrapertools, servertools
|
||||
from core.item import Item
|
||||
from platformcode import logger, config
|
||||
|
||||
host = "https://patrimonio.archivioluce.com"
|
||||
host2 = "https://www.archivioluce.com"
|
||||
|
||||
headers = [['Referer', host]]
|
||||
|
||||
PERPAGE = 7
|
||||
|
||||
|
||||
def mainlist(item):
|
||||
logger.info("kod.istitutoluce mainlist")
|
||||
itemlist = [
|
||||
Item(
|
||||
channel=item.channel,
|
||||
title="[COLOR azure]Archivio - Tutti i Filmati[/COLOR]",
|
||||
action="peliculas",
|
||||
url="%s/luce-web/search/result.html?query=&perPage=7" % host,
|
||||
thumbnail="http://www.archivioluce.com/wp-content/themes/wpbootstrap/bootstrap/img/luce-logo.png"
|
||||
),
|
||||
Item(
|
||||
channel=item.channel,
|
||||
title="[COLOR azure]Categorie Tematiche[/COLOR]",
|
||||
action="categorie",
|
||||
url="%s/navigazione-tematica/" % host2,
|
||||
thumbnail="http://www.archivioluce.com/wp-content/themes/wpbootstrap/bootstrap/img/luce-logo.png"
|
||||
),
|
||||
Item(
|
||||
channel=item.channel,
|
||||
title="[COLOR yellow]Cerca...[/COLOR]",
|
||||
action="search",
|
||||
thumbnail="http://dc467.4shared.com/img/fEbJqOum/s7/13feaf0c8c0/Search"
|
||||
)
|
||||
]
|
||||
|
||||
return itemlist
|
||||
|
||||
|
||||
def categorie(item):
|
||||
itemlist = []
|
||||
|
||||
data = httptools.downloadpage(item.url, headers=headers).data
|
||||
bloque = scrapertools.find_single_match(data, '<section class="container directory">(.*?)<footer class="main">')
|
||||
patron = '<a class="label label-white" href="(.*?)">\s*(.*?)</a>'
|
||||
matches = re.compile(patron, re.DOTALL).findall(bloque)
|
||||
|
||||
for scrapedurl, scrapedtitle in matches:
|
||||
scrapedtitle = scrapedtitle.title()
|
||||
itemlist.append(
|
||||
Item(channel=item.channel,
|
||||
action="cat_results",
|
||||
fulltitle=scrapedtitle,
|
||||
title=scrapedtitle,
|
||||
url=scrapedurl,
|
||||
viewmode="movie_with_plot",
|
||||
Folder=True))
|
||||
|
||||
return itemlist
|
||||
|
||||
|
||||
def cat_results(item):
|
||||
logger.info("kod.istitutoluce cat_results")
|
||||
itemlist = []
|
||||
|
||||
# Carica la pagina
|
||||
data = httptools.downloadpage(item.url, headers=headers).data
|
||||
|
||||
# Estrae i contenuti
|
||||
patron = '<a href="([^"]+)" class="thumbnail">\s*<h1>'
|
||||
matches = re.compile(patron, re.DOTALL).findall(data)
|
||||
|
||||
for scrapedurl in matches:
|
||||
scrapedtitle = scrapedurl
|
||||
scrapedtitle = scrapedtitle.rsplit('/', 1)[-1].rsplit(".", 1)[0].replace("-", " ").title()
|
||||
scrapedurl = host + scrapedurl
|
||||
scrapedplot = ""
|
||||
# html = scrapertools.cache_page(scrapedurl)
|
||||
# start = html.find('<p class="abstract">')
|
||||
# end = html.find('</p>', start)
|
||||
# scrapedplot = html[start:end]
|
||||
# scrapedplot = re.sub(r'<[^>]*>', '', scrapedplot)
|
||||
# scrapedplot = scrapertools.decodeHtmlentities(scrapedplot)
|
||||
scrapedthumbnail = ""
|
||||
# cache = httptools.downloadpage(scrapedurl, headers=headers).data
|
||||
# patron = 'image: "(.*?)"'
|
||||
# matches = re.compile(patron, re.DOTALL).findall(cache)
|
||||
# for scrapedthumbnail in matches:
|
||||
itemlist.append(
|
||||
Item(channel=item.channel,
|
||||
action="findvideos",
|
||||
fulltitle=scrapedtitle,
|
||||
show=scrapedtitle,
|
||||
title=scrapedtitle,
|
||||
url=scrapedurl,
|
||||
thumbnail=scrapedthumbnail,
|
||||
plot=scrapedplot,
|
||||
folder=True))
|
||||
|
||||
# Paginazione
|
||||
patron = r'</span></td>\s*<td>\s*<a href="([^"]+)" class="btn-pag-luce">'
|
||||
next_page = scrapertools.find_single_match(data, patron)
|
||||
|
||||
if next_page > 0:
|
||||
scrapedurl = urlparse.urljoin(item.url, next_page)
|
||||
itemlist.append(
|
||||
Item(channel=item.channel,
|
||||
action="cat_results",
|
||||
title="[COLOR lightgreen]" + config.get_localized_string(30992) + "[/COLOR]",
|
||||
url=scrapedurl,
|
||||
thumbnail="http://2.bp.blogspot.com/-fE9tzwmjaeQ/UcM2apxDtjI/AAAAAAAAeeg/WKSGM2TADLM/s1600/pager+old.png",
|
||||
folder=True))
|
||||
|
||||
return itemlist
|
||||
|
||||
|
||||
def peliculas(item):
|
||||
logger.info("kod.istitutoluce peliculas")
|
||||
itemlist = []
|
||||
|
||||
# Carica la pagina
|
||||
data = httptools.downloadpage(item.url, headers=headers).data
|
||||
|
||||
# Estrae i contenuti
|
||||
patron = '<a href="([^"]+)" class="thumbnail">\s*<h1>'
|
||||
matches = re.compile(patron, re.DOTALL).findall(data)
|
||||
|
||||
for scrapedurl in matches:
|
||||
scrapedtitle = scrapedurl
|
||||
scrapedtitle = scrapedtitle.rsplit('/', 1)[-1].rsplit(".", 1)[0].replace("-", " ").title()
|
||||
scrapedurl = host + scrapedurl
|
||||
|
||||
## html = scrapertools.cache_page(scrapedurl)
|
||||
html = httptools.downloadpage(scrapedurl, headers=headers).data
|
||||
start = html.find('<p class="abstract">')
|
||||
end = html.find('</p>', start)
|
||||
scrapedplot = html[start:end]
|
||||
scrapedplot = re.sub(r'<[^>]*>', '', scrapedplot)
|
||||
scrapedplot = scrapertools.decodeHtmlentities(scrapedplot)
|
||||
|
||||
html = httptools.downloadpage(scrapedurl, headers=headers).data
|
||||
patron = 'image: "(.*?)"'
|
||||
scrapedthumbnail = scrapertools.find_single_match(html, patron)
|
||||
|
||||
itemlist.append(
|
||||
Item(channel=item.channel,
|
||||
action="findvideos",
|
||||
fulltitle=scrapedtitle,
|
||||
show=scrapedtitle,
|
||||
title=scrapedtitle,
|
||||
url=scrapedurl,
|
||||
thumbnail=scrapedthumbnail,
|
||||
plot=scrapedplot,
|
||||
folder=True))
|
||||
|
||||
# Paginazione
|
||||
patron = r'</span></td>\s*<td>\s*<a href="([^"]+)" class="btn-pag-luce">'
|
||||
next_page = scrapertools.find_single_match(data, patron)
|
||||
|
||||
if next_page:
|
||||
scrapedurl = urlparse.urljoin(item.url, next_page)
|
||||
itemlist.append(
|
||||
Item(channel=item.channel,
|
||||
action="peliculas",
|
||||
title="[COLOR lightgreen]" + config.get_localized_string(30992) + "[/COLOR]",
|
||||
url=scrapedurl,
|
||||
thumbnail="http://2.bp.blogspot.com/-fE9tzwmjaeQ/UcM2apxDtjI/AAAAAAAAeeg/WKSGM2TADLM/s1600/pager+old.png",
|
||||
folder=True))
|
||||
|
||||
return itemlist
|
||||
|
||||
|
||||
def peliculas_src(item):
|
||||
logger.info("kod.istitutoluce peliculas")
|
||||
itemlist = []
|
||||
|
||||
p = 1
|
||||
if '{}' in item.url:
|
||||
item.url, p = item.url.split('{}')
|
||||
p = int(p)
|
||||
|
||||
# Carica la pagina
|
||||
data = httptools.downloadpage(item.url, headers=headers).data
|
||||
|
||||
# Estrae i contenuti
|
||||
patron = '<a href="([^"]+)" class="thumbnail">\s*<h1>'
|
||||
matches = re.compile(patron, re.DOTALL).findall(data)
|
||||
|
||||
for i, (scrapedurl) in enumerate(matches):
|
||||
if (p - 1) * PERPAGE > i: continue
|
||||
if i >= p * PERPAGE: break
|
||||
scrapedtitle = scrapedurl
|
||||
scrapedtitle = scrapedtitle.rsplit('/', 1)[-1].rsplit(".", 1)[0].replace("-", " ").title()
|
||||
scrapedurl = urlparse.urljoin(host, scrapedurl)
|
||||
|
||||
html = httptools.downloadpage(scrapedurl, headers=headers).data
|
||||
start = html.find('<p class="abstract">')
|
||||
end = html.find('</p>', start)
|
||||
scrapedplot = html[start:end]
|
||||
scrapedplot = re.sub(r'<[^>]*>', '', scrapedplot)
|
||||
scrapedplot = scrapertools.decodeHtmlentities(scrapedplot)
|
||||
|
||||
html = httptools.downloadpage(scrapedurl, headers=headers).data
|
||||
patron = 'image: "(.*?)"'
|
||||
scrapedthumbnail = scrapertools.find_single_match(html, patron)
|
||||
|
||||
itemlist.append(
|
||||
Item(channel=item.channel,
|
||||
action="findvideos",
|
||||
fulltitle=scrapedtitle,
|
||||
show=scrapedtitle,
|
||||
title=scrapedtitle,
|
||||
url=scrapedurl,
|
||||
thumbnail=scrapedthumbnail,
|
||||
plot=scrapedplot,
|
||||
folder=True))
|
||||
|
||||
# Paginazione
|
||||
if len(matches) >= p * PERPAGE:
|
||||
scrapedurl = item.url + '{}' + str(p + 1)
|
||||
itemlist.append(
|
||||
Item(channel=item.channel,
|
||||
extra=item.extra,
|
||||
action="peliculas_src",
|
||||
title="[COLOR lightgreen]" + config.get_localized_string(30992) + "[/COLOR]",
|
||||
url=scrapedurl,
|
||||
thumbnail="http://2.bp.blogspot.com/-fE9tzwmjaeQ/UcM2apxDtjI/AAAAAAAAeeg/WKSGM2TADLM/s1600/pager+old.png",
|
||||
folder=True))
|
||||
|
||||
return itemlist
|
||||
|
||||
|
||||
def search(item, texto):
|
||||
logger.info("[istitutoluce.py] search")
|
||||
|
||||
item.url = host + '/luce-web/search/result.html?archiveType_string="xDamsCineLuce"&archiveName_string="luceFondoCinegiornali"&archiveName_string="luceFondoDocumentari"&archiveName_string="luceFondoRepertori"&titoloADV=&descrizioneADV="' + texto + '"'
|
||||
|
||||
try:
|
||||
return peliculas_src(item)
|
||||
|
||||
# Continua la ricerca in caso di errore .
|
||||
except:
|
||||
import sys
|
||||
for line in sys.exc_info():
|
||||
logger.error("%s" % line)
|
||||
return []
|
||||
|
||||
|
||||
def findvideos(item):
|
||||
logger.info("kod.istitutoluce findvideos")
|
||||
|
||||
data = httptools.downloadpage(item.url, headers=headers).data
|
||||
|
||||
itemlist = servertools.find_video_items(data=data)
|
||||
|
||||
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
|
||||
|
||||
# Estrae i contenuti
|
||||
patron = 'file: "rtsp:([^"]+)"\s*}'
|
||||
matches = re.compile(patron, re.DOTALL).findall(data)
|
||||
|
||||
for video in matches:
|
||||
video = "rtsp:" + video
|
||||
itemlist.append(
|
||||
Item(
|
||||
channel=item.channel,
|
||||
action="play",
|
||||
title=item.title + " [[COLOR orange]Diretto[/COLOR]]",
|
||||
url=video,
|
||||
folder=False))
|
||||
|
||||
return itemlist
|
||||
@@ -15,7 +15,7 @@
|
||||
"""
|
||||
|
||||
import re
|
||||
from core import support, httptools, scrapertoolsV2
|
||||
from core import support, httptools, scrapertools
|
||||
from core.item import Item
|
||||
from platformcode import config
|
||||
|
||||
@@ -130,8 +130,8 @@ def findvideos(item):
|
||||
data = httptools.downloadpage(item.url, headers=headers).data
|
||||
data = re.sub('\n|\t', ' ', data)
|
||||
data = re.sub(r'>\s+<', '> <', data)
|
||||
url_video = scrapertoolsV2.find_single_match(data, r'<a rel="[^"]+" target="[^"]+" act="[^"]+"\s+href="([^"]+)" class="[^"]+-link".+?\d+.+?</strong> </a>', -1)
|
||||
url_serie = scrapertoolsV2.find_single_match(data, r'<link rel="canonical" href="([^"]+)" />')
|
||||
url_video = scrapertools.find_single_match(data, r'<a rel="[^"]+" target="[^"]+" act="[^"]+"\s+href="([^"]+)" class="[^"]+-link".+?\d+.+?</strong> </a>', -1)
|
||||
url_serie = scrapertools.find_single_match(data, r'<link rel="canonical" href="([^"]+)" />')
|
||||
goseries = support.typo("Vai alla Serie:", ' bold')
|
||||
series = support.typo(item.contentSerieName, ' bold color kod')
|
||||
itemlist = support.server(item, data=url_video)
|
||||
|
||||
@@ -1,21 +0,0 @@
|
||||
{
|
||||
"id": "programmazione",
|
||||
"name": "Programmazione",
|
||||
"language": ["ita"],
|
||||
"active": true,
|
||||
"adult": false,
|
||||
"thumbnail": "http://www.smartworld.it/wp-content/uploads/2015/02/codice-code-programmazione-fhd-720x480.png",
|
||||
"banner": "http://www.smartworld.it/wp-content/uploads/2015/02/codice-code-programmazione-fhd-720x480.png",
|
||||
"categories": ["documentary"],
|
||||
"settings": [
|
||||
{
|
||||
"id": "include_in_global_search",
|
||||
"type": "bool",
|
||||
"label": "Incluir en busqueda global",
|
||||
"default": false,
|
||||
"enabled": false,
|
||||
"visible": false
|
||||
}
|
||||
]
|
||||
}
|
||||
|
||||
@@ -1,71 +0,0 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# ------------------------------------------------------------
|
||||
# Ringraziamo Icarus crew
|
||||
# Canale Video Corsi Programmazione
|
||||
# Creato da iSOD
|
||||
# https://alfa-addon.com/categories/kod-addon.50/.
|
||||
# ------------------------------------------------------------
|
||||
import re
|
||||
|
||||
from core import httptools, scrapertools
|
||||
from core.item import Item
|
||||
from platformcode import logger
|
||||
from platformcode import config
|
||||
|
||||
site = "https://www.youtube.com"
|
||||
|
||||
|
||||
def mainlist(item):
|
||||
logger.info("kod.programmazione mainlist")
|
||||
itemlist = []
|
||||
itemlist.append( Item(channel=item.channel, title="[COLOR azure]Corso Html 5[/COLOR]", action="corsi", url="https://www.youtube.com/playlist?list=PL7A4A3449C649048F", thumbnail="http://i.ytimg.com/vi/TyCvfNt20nM/mqdefault.jpg"))
|
||||
itemlist.append( Item(channel=item.channel, title="[COLOR azure]Corso Css[/COLOR]", action="corsi", url="https://www.youtube.com/playlist?list=PLD74C5E763D39793D", thumbnail="http://i.ytimg.com/vi/hd8k82aG_O4/mqdefault.jpg"))
|
||||
itemlist.append( Item(channel=item.channel, title="[COLOR azure]Corso Javascript[/COLOR]", action="corsi", url="https://www.youtube.com/playlist?list=PL1A447BA7F7F9EB9E", thumbnail="http:////i.ytimg.com/vi/eXlzdxyThLM/mqdefault.jpg"))
|
||||
itemlist.append( Item(channel=item.channel, title="[COLOR azure]Corso PHP[/COLOR]", action="corsi", url="https://www.youtube.com/playlist?list=PL0qAPtx8YtJc664i2Cv0X0ibM9b1YqRyd", thumbnail="http://i.ytimg.com/vi/0nA1gPWdBWw/mqdefault.jpg"))
|
||||
itemlist.append( Item(channel=item.channel, title="[COLOR azure]Corso PHP Mysql[/COLOR]", action="corsi", url="https://www.youtube.com/playlist?list=PL101314D973955661", thumbnail="http://i.ytimg.com/vi/QIxmITjITY8/mqdefault.jpg"))
|
||||
itemlist.append( Item(channel=item.channel, title="[COLOR azure]Corso Jquery[/COLOR]", action="corsi", url="https://www.youtube.com/playlist?list=PLC959BB22285B353F", thumbnail="http://i.ytimg.com/vi/mxl2IcNdbrk/mqdefault.jpg"))
|
||||
itemlist.append( Item(channel=item.channel, title="[COLOR azure]Corso Java da Zero[/COLOR]", action="corsi", url="https://www.youtube.com/playlist?list=PL0qAPtx8YtJe2dpE7di4aPJwrQuRD6IDD", thumbnail="http://i.ytimg.com/vi/7PGPLqFpDMc/mqdefault.jpg"))
|
||||
itemlist.append( Item(channel=item.channel, title="[COLOR azure]Corso Java 2 OOP[/COLOR]", action="corsi", url="https://www.youtube.com/playlist?list=PL0qAPtx8YtJee1dk24wX-68yHTnMfzdX5", thumbnail="http://i.ytimg.com/vi/h6VoxIAUZoo/mqdefault.jpg"))
|
||||
itemlist.append( Item(channel=item.channel, title="[COLOR azure]Corso Java Interfaccia Grafica[/COLOR]", action="corsi", url="https://www.youtube.com/playlist?list=PL0qAPtx8YtJfRML8EDs7v9nwjdOt6dvaf", thumbnail="http://i.ytimg.com/vi/fS7OxhbIlw4/mqdefault.jpg"))
|
||||
itemlist.append( Item(channel=item.channel, title="[COLOR azure]Corso Java Android[/COLOR]", action="corsi", url="https://www.youtube.com/playlist?list=PL0qAPtx8YtJeqmBWbE1Rbac2QWHoPCjR2", thumbnail="http://i.ytimg.com/vi/GINLfdq-elE/mqdefault.jpg"))
|
||||
itemlist.append( Item(channel=item.channel, title="[COLOR azure]Corso Progettazione DB[/COLOR]", action="corsi", url="https://www.youtube.com/playlist?list=PL0qAPtx8YtJcJPSV4sOfhLtPbtQ-yycFH", thumbnail="http://i.ytimg.com/vi/FnkL4YdWAwE/mqdefault.jpg"))
|
||||
itemlist.append( Item(channel=item.channel, title="[COLOR azure]Corso SQL[/COLOR]", action="corsi", url="https://www.youtube.com/playlist?list=PLE555DB6188C967AC", thumbnail="http://i.ytimg.com/vi/jM55Fb9YTfE/mqdefault.jpg"))
|
||||
itemlist.append( Item(channel=item.channel, title="[COLOR azure]Corso Python[/COLOR]", action="corsi", url="https://www.youtube.com/playlist?list=PLC64779F4E2E7EB10", thumbnail="http://i.ytimg.com/vi/_iX9CSX09Z8/mqdefault.jpg"))
|
||||
itemlist.append( Item(channel=item.channel, title="[COLOR azure]Corso Unit 3D[/COLOR]", action="corsi", url="https://www.youtube.com/playlist?list=PL0qAPtx8YtJcbl6ZHwtFIkFxWY-adCeS7", thumbnail="http://i.ytimg.com/vi/QiFBrHp3IGk/mqdefault.jpg"))
|
||||
|
||||
return itemlist
|
||||
|
||||
|
||||
def corsi(item):
|
||||
logger.info("kod.programmazione peliculas")
|
||||
itemlist = []
|
||||
|
||||
# scarrico il canale
|
||||
html = httptools.downloadpage(item.url).data
|
||||
|
||||
# Estraggo l'elenco dei video e titoli
|
||||
patron = '<a class="pl-video-title-link.*?href="(.*?)"[^>]+>(.*?)</a>'
|
||||
trovati = re.compile(patron, re.DOTALL).findall(html)
|
||||
scrapertools.printMatches(trovati)
|
||||
max = len(trovati)
|
||||
min = 0
|
||||
|
||||
# ciclo sull'elenco trovato
|
||||
for VideoUrl, VideoTitolo in trovati:
|
||||
# Decodifico Html
|
||||
titolo = scrapertools.decodeHtmlentities(VideoTitolo)
|
||||
# contatore
|
||||
min += 1
|
||||
# aggiungo alla lista
|
||||
itemlist.append(
|
||||
Item(channel=item.channel,
|
||||
action="findvideos",
|
||||
fulltitle=titolo,
|
||||
show=titolo,
|
||||
title="[COLOR azure]" + item.title + " - " + str(min) + "x" + str(max) + "[/COLOR]",
|
||||
url=site + VideoUrl,
|
||||
thumbnail=item.thumbnail,
|
||||
plot=titolo,
|
||||
folder=True))
|
||||
|
||||
return itemlist
|
||||
File diff suppressed because it is too large
Load Diff
@@ -1,37 +0,0 @@
|
||||
{
|
||||
"id": "ricettevideo",
|
||||
"name": "Ricette Video",
|
||||
"language": ["ita"],
|
||||
"active": true,
|
||||
"adult": false,
|
||||
"thumbnail": "http://ricettevideo.net/wp-content/uploads/2013/08/Ricette-Video-Logo.png",
|
||||
"banner": "http://ricettevideo.net/wp-content/uploads/2013/08/Ricette-Video-Logo.png",
|
||||
"categories": ["documentary"],
|
||||
"settings": [
|
||||
{
|
||||
"id": "include_in_global_search",
|
||||
"type": "bool",
|
||||
"label": "Incluir en busqueda global",
|
||||
"default": false,
|
||||
"enabled": false,
|
||||
"visible": false
|
||||
},
|
||||
{
|
||||
"id": "include_in_newest_documentales",
|
||||
"type": "bool",
|
||||
"label": "Includi in Novità - Documentari",
|
||||
"default": true,
|
||||
"enabled": true,
|
||||
"visible": true
|
||||
},
|
||||
{
|
||||
"id": "include_in_newest_italiano",
|
||||
"type": "bool",
|
||||
"label": "Includi in Novità - Italiano",
|
||||
"default": true,
|
||||
"enabled": true,
|
||||
"visible": true
|
||||
}
|
||||
]
|
||||
}
|
||||
|
||||
@@ -1,58 +0,0 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# ------------------------------------------------------------
|
||||
# Ringraziamo Icarus crew
|
||||
# Canale ricettevideo
|
||||
# ------------------------------------------------------------
|
||||
import re
|
||||
import urlparse
|
||||
|
||||
from core import httptools, scrapertools
|
||||
from core.item import Item
|
||||
from platformcode import logger
|
||||
from platformcode import config
|
||||
|
||||
host = "http://ricettevideo.net"
|
||||
|
||||
|
||||
def mainlist(item):
|
||||
logger.info("kod.ricettevideo mainlist")
|
||||
itemlist = [Item(channel=item.channel, title="[COLOR azure]Videoricette[/COLOR]", action="peliculas",
|
||||
url=host,
|
||||
thumbnail="http://www.brinkmanscountrycorner.com/images/Recipies.png")]
|
||||
|
||||
return itemlist
|
||||
|
||||
|
||||
def peliculas(item):
|
||||
logger.info("kod.ricettevideo peliculas")
|
||||
itemlist = []
|
||||
|
||||
# Carica la pagina
|
||||
data = httptools.downloadpage(item.url).data
|
||||
|
||||
# Estrae i contenuti
|
||||
patron = '<div class="post-item-small">\s*<a href="([^"]+)"[^t]+title="Permanent Link: ([^"]+)"><img[^s]+src="([^"]+)"[^>]+>'
|
||||
matches = re.compile(patron, re.DOTALL).findall(data)
|
||||
scrapertools.printMatches(matches)
|
||||
|
||||
for scrapedurl, scrapedtitle, scrapedthumbnail in matches:
|
||||
scrapedtitle = scrapertools.decodeHtmlentities(scrapedtitle)
|
||||
scrapedplot = ""
|
||||
itemlist.append(Item(channel=item.channel, action="findvideos", fulltitle=scrapedtitle, show=scrapedtitle,
|
||||
title=scrapedtitle, url=scrapedurl, thumbnail=scrapedthumbnail, plot=scrapedplot,
|
||||
folder=True))
|
||||
|
||||
# Paginazione
|
||||
patronvideos = '<link rel=\'next\' href=\'([^\']+)\' />'
|
||||
matches = re.compile(patronvideos, re.DOTALL).findall(data)
|
||||
scrapertools.printMatches(matches)
|
||||
|
||||
if len(matches) > 0:
|
||||
scrapedurl = urlparse.urljoin(item.url, matches[0])
|
||||
itemlist.append(
|
||||
Item(channel=item.channel, action="peliculas", title="[COLOR orange]Avanti >>[/COLOR]", url=scrapedurl,
|
||||
folder=True))
|
||||
|
||||
return itemlist
|
||||
|
||||
# test update
|
||||
+2
-2
@@ -4,7 +4,7 @@
|
||||
# ------------------------------------------------------------
|
||||
|
||||
|
||||
from core import scrapertoolsV2, httptools, support
|
||||
from core import scrapertools, httptools, support
|
||||
from core.item import Item
|
||||
|
||||
host = support.config.get_channel_url()
|
||||
@@ -17,7 +17,7 @@ headers = [['Referer', host]]
|
||||
# global host, headers
|
||||
# data= httptools.downloadpage('https://seriehd.nuovo.link/').data
|
||||
# global host, headers
|
||||
# host = scrapertoolsV2.find_single_match(data, r'<div class="elementor-button-wrapper"> <a href="([^"]+)"')
|
||||
# host = scrapertools.find_single_match(data, r'<div class="elementor-button-wrapper"> <a href="([^"]+)"')
|
||||
# headers = [['Referer', host]]
|
||||
|
||||
list_servers = ['verystream', 'openload', 'streamango', 'thevideome']
|
||||
|
||||
@@ -16,14 +16,14 @@
|
||||
- Prima fare la 'Rinumerazione' dal menu contestuale dal titolo della serie
|
||||
"""
|
||||
import re
|
||||
from core import support, httptools, scrapertoolsV2
|
||||
from core import support, httptools, scrapertools
|
||||
from platformcode import config
|
||||
from core.item import Item
|
||||
|
||||
|
||||
def findhost():
|
||||
data = httptools.downloadpage('https://serietvonline.me/').data
|
||||
host = scrapertoolsV2.find_single_match(data, r'<a class="pure-button pure-button-primary" title=\'serie tv online\' href="([^"]+)">')
|
||||
host = scrapertools.find_single_match(data, r'<a class="pure-button pure-button-primary" title=\'serie tv online\' href="([^"]+)">')
|
||||
return host
|
||||
|
||||
host = config.get_channel_url(findhost)
|
||||
@@ -180,8 +180,8 @@ def findvideos(item):
|
||||
data = re.sub('\n|\t', ' ', data)
|
||||
data = re.sub(r'>\s+<', '> <', data)
|
||||
#support.log("DATA - HTML:\n", data)
|
||||
url_video = scrapertoolsV2.find_single_match(data, r'<tr><td>(.+?)</td><tr>', -1)
|
||||
url_serie = scrapertoolsV2.find_single_match(data, r'<link rel="canonical" href="([^"]+)"\s?/>')
|
||||
url_video = scrapertools.find_single_match(data, r'<tr><td>(.+?)</td><tr>', -1)
|
||||
url_serie = scrapertools.find_single_match(data, r'<link rel="canonical" href="([^"]+)"\s?/>')
|
||||
goseries = support.typo("Vai alla Serie:", ' bold')
|
||||
series = support.typo(item.contentSerieName, ' bold color kod')
|
||||
itemlist = support.server(item, data=url_video)
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
"""
|
||||
import re
|
||||
|
||||
from core import support, httptools, scrapertoolsV2
|
||||
from core import support, httptools, scrapertools
|
||||
from core.item import Item
|
||||
from core.support import log
|
||||
from platformcode import config
|
||||
@@ -118,8 +118,8 @@ def findvideos(item):
|
||||
data = httptools.downloadpage(item.url, headers=headers).data
|
||||
data = re.sub('\n|\t', ' ', data)
|
||||
data = re.sub(r'>\s+<', '> <', data)
|
||||
url_video = scrapertoolsV2.find_single_match(data, r'<div class="item"> <a data-id="[^"]+" data-href="([^"]+)" data-original="[^"]+"[^>]+> <div> <div class="title">Episodio \d+', -1)
|
||||
url_serie = scrapertoolsV2.find_single_match(data, r'<link rel="canonical" href="([^"]+)"\s?/>')
|
||||
url_video = scrapertools.find_single_match(data, r'<div class="item"> <a data-id="[^"]+" data-href="([^"]+)" data-original="[^"]+"[^>]+> <div> <div class="title">Episodio \d+', -1)
|
||||
url_serie = scrapertools.find_single_match(data, r'<link rel="canonical" href="([^"]+)"\s?/>')
|
||||
goseries = support.typo(">> Vai alla Serie:", ' bold')
|
||||
series = support.typo(item.contentSerieName, ' bold color kod')
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
from core import support, httptools, scrapertoolsV2
|
||||
from core import support, httptools, scrapertools
|
||||
from core.item import Item
|
||||
from platformcode import config, logger
|
||||
|
||||
@@ -113,7 +113,7 @@ def episodios(item):
|
||||
stagioni[st] = nEp
|
||||
|
||||
itemlist = []
|
||||
domain, id = scrapertoolsV2.find_single_match(url, r'(https?://[a-z0-9.-]+)/[^/]+/([^-/]+)')
|
||||
domain, id = scrapertools.find_single_match(url, r'(https?://[a-z0-9.-]+)/[^/]+/([^-/]+)')
|
||||
for st in sorted(stagioni.keys()):
|
||||
season = st[1:]
|
||||
episode = stagioni[st]
|
||||
@@ -140,7 +140,7 @@ def episodios(item):
|
||||
|
||||
def findvideos(item):
|
||||
# support.dbg()
|
||||
domain = scrapertoolsV2.find_single_match(item.url, 'https?://[a-z0-9.-]+')
|
||||
domain = scrapertools.find_single_match(item.url, 'https?://[a-z0-9.-]+')
|
||||
if item.contentType == 'movie':
|
||||
id = item.url.split('/')[-1]
|
||||
url = domain + '/play_f.php?f=' + id
|
||||
|
||||
+14
-14
@@ -7,7 +7,7 @@ import re
|
||||
|
||||
import urlparse
|
||||
|
||||
from core import scrapertoolsV2, httptools, tmdb, support,servertools
|
||||
from core import scrapertools, httptools, tmdb, support,servertools
|
||||
from core.item import Item
|
||||
from core.support import menu, log
|
||||
from platformcode import logger
|
||||
@@ -22,7 +22,7 @@ def findhost():
|
||||
pass
|
||||
# global host, headers
|
||||
# permUrl = httptools.downloadpage('https://www.tantifilm.info/', follow_redirects=False).data
|
||||
# host = scrapertoolsV2.find_single_match(permUrl, r'<h2 style="text-align: center;"><a href="([^"]+)">Il nuovo indirizzo di Tantifilm è:</a></h2>')
|
||||
# host = scrapertools.find_single_match(permUrl, r'<h2 style="text-align: center;"><a href="([^"]+)">Il nuovo indirizzo di Tantifilm è:</a></h2>')
|
||||
# if host.endswith('/'):
|
||||
# host = host[:-1]
|
||||
# headers = [['Referer', host]]
|
||||
@@ -90,7 +90,7 @@ def episodios(item):
|
||||
else:
|
||||
data_check = item.data
|
||||
patron_check = r'<iframe src="([^"]+)" scrolling="no" frameborder="0" width="626" height="550" allowfullscreen="true" webkitallowfullscreen="true" mozallowfullscreen="true">'
|
||||
item.url = scrapertoolsV2.find_single_match(data_check, patron_check)
|
||||
item.url = scrapertools.find_single_match(data_check, patron_check)
|
||||
|
||||
patronBlock = r'Stagioni<\/a>.*?<ul class="nav navbar-nav">(?P<block>.*?)<\/ul>'
|
||||
patron = r'<a href="(?P<url>[^"]+)"\s*>\s*<i[^>]+><\/i>\s*(?P<episode>\d+)<\/a>'
|
||||
@@ -105,8 +105,8 @@ def episodios(item):
|
||||
season_data = httptools.downloadpage(item.url).data
|
||||
season_data = re.sub('\n|\t', ' ', season_data)
|
||||
season_data = re.sub(r'>\s+<', '> <', season_data)
|
||||
block = scrapertoolsV2.find_single_match(season_data, 'Episodi.*?<ul class="nav navbar-nav">(.*?)</ul>')
|
||||
episodes = scrapertoolsV2.find_multiple_matches(block, '<a href="([^"]+)"\s*>\s*<i[^>]+><\/i>\s*(\d+)<\/a>')
|
||||
block = scrapertools.find_single_match(season_data, 'Episodi.*?<ul class="nav navbar-nav">(.*?)</ul>')
|
||||
episodes = scrapertools.find_multiple_matches(block, '<a href="([^"]+)"\s*>\s*<i[^>]+><\/i>\s*(\d+)<\/a>')
|
||||
for url, episode in episodes:
|
||||
i = item.clone()
|
||||
i.action = 'findvideos'
|
||||
@@ -136,9 +136,9 @@ def anime(item):
|
||||
|
||||
seasons = support.match(item, r'<div class="sp-body[^"]+">(.*?)<\/div>')[0]
|
||||
for season in seasons:
|
||||
episodes = scrapertoolsV2.find_multiple_matches(season, r'<a.*?href="([^"]+)"[^>]+>([^<]+)<\/a>(.*?)<(:?br|\/p)')
|
||||
episodes = scrapertools.find_multiple_matches(season, r'<a.*?href="([^"]+)"[^>]+>([^<]+)<\/a>(.*?)<(:?br|\/p)')
|
||||
for url, title, urls, none in episodes:
|
||||
urls = scrapertoolsV2.find_multiple_matches(urls, '<a.*?href="([^"]+)"[^>]+>')
|
||||
urls = scrapertools.find_multiple_matches(urls, '<a.*?href="([^"]+)"[^>]+>')
|
||||
|
||||
for url2 in urls:
|
||||
url += url2 + '\n'
|
||||
@@ -192,8 +192,8 @@ def search(item, texto):
|
||||
## for url, title, year, thumb, quality in matches:
|
||||
## infoLabels = {}
|
||||
## infoLabels['year'] = year
|
||||
## title = scrapertoolsV2.decodeHtmlentities(title)
|
||||
## quality = scrapertoolsV2.decodeHtmlentities(quality)
|
||||
## title = scrapertools.decodeHtmlentities(title)
|
||||
## quality = scrapertools.decodeHtmlentities(quality)
|
||||
## longtitle = title + support.typo(quality,'_ [] color kod')
|
||||
## itemlist.append(
|
||||
## Item(channel=item.channel,
|
||||
@@ -221,7 +221,7 @@ def newest(categoria):
|
||||
matches = support.match(item, r'mediaWrapAlt recomended_videos"[^>]+>\s*<a href="([^"]+)" title="([^"]+)" rel="bookmark">\s*<img[^s]+src="([^"]+)"[^>]+>')[0]
|
||||
|
||||
for url, title, thumb in matches:
|
||||
title = scrapertoolsV2.decodeHtmlentities(title).replace("Permalink to ", "").replace("streaming", "")
|
||||
title = scrapertools.decodeHtmlentities(title).replace("Permalink to ", "").replace("streaming", "")
|
||||
title = re.sub(r'\s\(\d+\)','',title)
|
||||
itemlist.append(
|
||||
Item(channel=item.channel,
|
||||
@@ -250,7 +250,7 @@ def findvideos(item):
|
||||
|
||||
data = re.sub('\n|\t', ' ', data)
|
||||
data = re.sub(r'>\s+<', '> <', data)
|
||||
check = scrapertoolsV2.find_single_match(data, r'<div class="category-film">\s+<h3>\s+(.*?)\s+</h3>\s+</div>')
|
||||
check = scrapertools.find_single_match(data, r'<div class="category-film">\s+<h3>\s+(.*?)\s+</h3>\s+</div>')
|
||||
if 'sub' in check.lower():
|
||||
item.contentLanguage = 'Sub-ITA'
|
||||
support.log("CHECK : ", check)
|
||||
@@ -265,7 +265,7 @@ def findvideos(item):
|
||||
return episodios(item)
|
||||
|
||||
if 'protectlink' in data:
|
||||
urls = scrapertoolsV2.find_multiple_matches(data, r'<iframe src="[^=]+=(.*?)"')
|
||||
urls = scrapertools.find_multiple_matches(data, r'<iframe src="[^=]+=(.*?)"')
|
||||
support.log("SONO QUI: ", urls)
|
||||
for url in urls:
|
||||
url = url.decode('base64')
|
||||
@@ -273,7 +273,7 @@ def findvideos(item):
|
||||
url, c = unshorten_only(url)
|
||||
if 'nodmca' in url:
|
||||
page = httptools.downloadpage(url, headers=headers).data
|
||||
url = '\t' + scrapertoolsV2.find_single_match(page,'<meta name="og:url" content="([^=]+)">')
|
||||
url = '\t' + scrapertools.find_single_match(page, '<meta name="og:url" content="([^=]+)">')
|
||||
if url:
|
||||
listurl.add(url)
|
||||
return support.server(item, data=listurl if listurl else data)#, headers=headers)
|
||||
@@ -286,7 +286,7 @@ def findvideos(item):
|
||||
## data = item.url if item.contentType == "episode" else httptools.downloadpage(item.url, headers=headers).data
|
||||
##
|
||||
## if 'protectlink' in data:
|
||||
## urls = scrapertoolsV2.find_multiple_matches(data, r'<iframe src="[^=]+=(.*?)"')
|
||||
## urls = scrapertools.find_multiple_matches(data, r'<iframe src="[^=]+=(.*?)"')
|
||||
## for url in urls:
|
||||
## url = url.decode('base64')
|
||||
## data += '\t' + url
|
||||
|
||||
+2
-2
@@ -3,7 +3,7 @@
|
||||
# Canale per vedohd
|
||||
# ------------------------------------------------------------
|
||||
|
||||
from core import scrapertoolsV2, httptools, support
|
||||
from core import scrapertools, httptools, support
|
||||
from core.item import Item
|
||||
from platformcode import logger, config
|
||||
from specials import autoplay
|
||||
@@ -47,7 +47,7 @@ def findvideos(item):
|
||||
for link in support.dooplay_get_links(item, host):
|
||||
if link['title'] != 'Trailer':
|
||||
logger.info(link['title'])
|
||||
server, quality = scrapertoolsV2.find_single_match(link['title'], '([^ ]+) ?(HD|3D)?')
|
||||
server, quality = scrapertools.find_single_match(link['title'], '([^ ]+) ?(HD|3D)?')
|
||||
if quality:
|
||||
title = server + " [COLOR blue][" + quality + "][/COLOR]"
|
||||
else:
|
||||
|
||||
Reference in New Issue
Block a user