fix cineblog

This commit is contained in:
marco
2019-10-18 21:09:07 +02:00
parent 7bc350d8ab
commit 76c763dff0
+7 -6
View File
@@ -19,12 +19,13 @@ headers = ""
def findhost():
global host, headers
permUrl = httptools.downloadpage('https://www.cb01.uno/', follow_redirects=False).headers
support.log('HOST= ',permUrl)
host = permUrl['location'].replace('https://www.google.it/search?q=site:', '').replace('https://www.google.it/search?&q=', '')
support.log('HOST ',host, ' ', host[:4])
if host[:4] != 'http':
host = 'https://' + host
support.log('HOST= ',host)
if 'google' in permUrl['location']:
if host[:4] != 'http':
host = 'https://'+permUrl['location'].replace('https://www.google.it/search?q=site:', '')
else:
host = permUrl['location'].replace('https://www.google.it/search?q=site:', '')
else:
host = permUrl['location']
headers = [['Referer', host]]
IDIOMAS = {'Italiano': 'IT'}