def SEARCHTV(url = ''): encode = main.updateSearchFile(url,'TV') if not encode: return False surl=base_url + 'index.php?search=' + encode + '&tv=&x=0&y=0' link=main.OPENURL(surl) link=link.replace('\r','').replace('\n','').replace('\t','').replace(' ','') match = re.findall('<a href="([^"]*)"><img alt="[^"]*" src="([^"]*)" /></a><div class="title"><a title="[^"]*" href="[^"]*">([^"]*)</a></div><ul class=\'star-rating\'><li class="current-rating" style="[^"]*"></li></ul><div class="item-genres"><a href="[^"]*">([^"]*)</a>',link) dialogWait = xbmcgui.DialogProgress() ret = dialogWait.create('Please wait until Movie list is cached.') totalLinks = len(match) loadedLinks = 0 remaining_display = 'Movies loaded :: [B]'+str(loadedLinks)+' / '+str(totalLinks)+'[/B].' dialogWait.update(0, '[B]Will load instantly from now on[/B]',remaining_display) for url,thumb,name,genre in match: name=name.replace('-','').replace('&','').replace('acute;','').strip() main.addDir(name+'[COLOR blue] Genre: '+genre+'[/COLOR]',base_url+url,12,'','') loadedLinks = loadedLinks + 1 percent = (loadedLinks * 100)/totalLinks remaining_display = 'Movies loaded :: [B]'+str(loadedLinks)+' / '+str(totalLinks)+'[/B].' dialogWait.update(percent,'[B]Will load instantly from now on[/B]',remaining_display) if (dialogWait.iscanceled()): return False dialogWait.close() del dialogWait nextpage=re.compile('<a href="([^"]*)" class="next">Next »</a>').findall(link) for url in nextpage: main.addDir('Next Page >>',base_url+url,1,art+'/next.png') xbmcplugin.setContent(int(sys.argv[1]), 'Movies') main.VIEWS()
def SEARCHTV(url=""): encode = main.updateSearchFile(url, "TV") if not encode: return False surl = base_url + "index.php?search=" + encode + "&tv=&x=0&y=0" link = main.OPENURL(surl) link = link.replace("\r", "").replace("\n", "").replace("\t", "").replace(" ", "") match = re.findall( '<a href="([^"]*)"><img alt="[^"]*" src="([^"]*)" /></a><div class="title"><a title="[^"]*" href="[^"]*">([^"]*)</a></div><ul class=\'star-rating\'><li class="current-rating" style="[^"]*"></li></ul><div class="item-genres"><a href="[^"]*">([^"]*)</a>', link, ) dialogWait = xbmcgui.DialogProgress() ret = dialogWait.create("Please wait until Movie list is cached.") totalLinks = len(match) loadedLinks = 0 remaining_display = "Movies loaded :: [B]" + str(loadedLinks) + " / " + str(totalLinks) + "[/B]." dialogWait.update(0, "[B]Will load instantly from now on[/B]", remaining_display) for url, thumb, name, genre in match: name = name.replace("-", "").replace("&", "").replace("acute;", "").strip() main.addDir(name + "[COLOR blue] Genre: " + genre + "[/COLOR]", base_url + url, 12, "", "") loadedLinks = loadedLinks + 1 percent = (loadedLinks * 100) / totalLinks remaining_display = "Movies loaded :: [B]" + str(loadedLinks) + " / " + str(totalLinks) + "[/B]." dialogWait.update(percent, "[B]Will load instantly from now on[/B]", remaining_display) if dialogWait.iscanceled(): return False dialogWait.close() del dialogWait nextpage = re.compile('<a href="([^"]*)" class="next">Next »</a>').findall(link) for url in nextpage: main.addDir("Next Page >>", base_url + url, 1, art + "/next.png") xbmcplugin.setContent(int(sys.argv[1]), "Movies") main.VIEWS()
def SEARCH(url = ''): encode = main.updateSearchFile(url,'Movies') if not encode: return False surl='http://www.filmesonlinegratis.net/?s=' + encode + '&s-btn=Buscar' link=main.OPEN_URL(surl) link=link.replace('\r','').replace('\n','').replace('\t','').replace(' ','').replace('– ',' - ') match = re.findall('title="([^"]*)">[^"]*</a></h2><divclass="capa"> <ahref="([^"]*)"><imgsrc="http://static.filmesonlinegratis.net/thumb.php[?]src=([^"]*)&w=135&h=185" alt="[^"]*" title="[^"]*" /></a> <spanclass="qualidade">([^"]*)</span>',link) dialogWait = xbmcgui.DialogProgress() ret = dialogWait.create('Please wait until Movie list is cached.') totalLinks = len(match) loadedLinks = 0 remaining_display = 'Movies loaded :: [B]'+str(loadedLinks)+' / '+str(totalLinks)+'[/B].' dialogWait.update(0, '[B]Will load instantly from now on[/B]',remaining_display) for name,url,thumb,quality in match: #main.addDirb(name+'[COLOR blue] Quality: '+quality+'[/COLOR]',str(url),8,thumb,'') main.addInfo(name+'[COLOR blue] Quality: '+quality+'[/COLOR]',url,8,thumb,'','') loadedLinks = loadedLinks + 1 percent = (loadedLinks * 100)/totalLinks remaining_display = 'Movies loaded :: [B]'+str(loadedLinks)+' / '+str(totalLinks)+'[/B].' dialogWait.update(percent,'[B]Will load instantly from now on[/B]',remaining_display) if (dialogWait.iscanceled()): return False dialogWait.close() del dialogWait nextpage=re.compile('href="([^"]*)">\xc2\xbb</a>').findall(link) for url in nextpage: main.addDir('Next Page >>',base_url+url,1,art+'/next.png') xbmcplugin.setContent(int(sys.argv[1]), 'Movies') main.VIEWS()
def SEARCH(murl = ''): encode = main.updateSearchFile(murl,'Movies') if not encode: return False surl=MainUrl+'/search.php?key='+encode+'&submit=' link=main.OPENURL(surl) link=link.replace('\r','').replace('\n','').replace('\t','').replace(' ','') match=re.compile('<div class="movie_pic"><a href="(.+?)" target=".+?"> <img src="(.+?)" width=".+?" height=".+?" />.+?<a href=".+?" target=".+?">(.+?)</a></h1><div class=".+?">Genre: <a href=".+?" target=\'.+?\'>(.+?)</a>.+?Release:.+?<br/>Views: <span>(.+?)</span>.+?id=RateCount_.+?>(.+?)</span> votes.+?>score:(.+?)</div>').findall(link) dialogWait = xbmcgui.DialogProgress() ret = dialogWait.create('Please wait until Movie list is cached.') totalLinks = len(match) loadedLinks = 0 remaining_display = 'Movies loaded :: [B]'+str(loadedLinks)+' / '+str(totalLinks)+'[/B].' dialogWait.update(0, '[B]Will load instantly from now on[/B]',remaining_display) xbmc.executebuiltin("XBMC.Dialog.Close(busydialog,true)") for url,thumb,name,genre,views,votes,rating in match: name=name.replace('-','').replace('&','').replace('acute;','') furl= MainUrl+url main.addInfo(name+'[COLOR blue] Views: '+views+'[/COLOR] [COLOR red]Votes: '+votes+'[/COLOR] [COLOR green]Rating: '+rating+'/5.00[/COLOR]',furl,3,thumb,genre,'') loadedLinks = loadedLinks + 1 percent = (loadedLinks * 100)/totalLinks remaining_display = 'Movies loaded :: [B]'+str(loadedLinks)+' / '+str(totalLinks)+'[/B].' dialogWait.update(percent,'[B]Will load instantly from now on[/B]',remaining_display) if dialogWait.iscanceled(): return False dialogWait.close() del dialogWait exist = re.findall("<a href='search.php.?page=.+?'>Next</a>",link) if exist: r = re.findall(""">Next</a><a href='search.php.?page=([^<]+)&key=.+?'>Last</a>""",link) if r: main.addDir('[COLOR blue]Page 1 of '+r[0]+'[/COLOR]','http://www.movie25.so/search.php?page=2&key='+encode,9,art+'/next2.png') else: main.addDir('[COLOR blue]Page 1[/COLOR]','http://www.movie25.so/search.php?page=2&key='+encode,9,art+'/next2.png') xbmcplugin.setContent(int(sys.argv[1]), 'Movies') main.GA("None","Movie25-Search")
def SEARCH(url=''): encode = main.updateSearchFile(url, 'TV') if not encode: return False surl = 'http://videobull.to/?s=' + encode + '&x=0&y=0' link = main.OPENURL(surl) link = link.replace('\r', '').replace('\n', '').replace('\t', '').replace(' ', '') match = re.compile( 'class="cover"><a href="([^"]*)" rel="bookmark" title="([^"]*)"><img src="([^"]*)"' ).findall(link) if len(match) > 0: for url, name, thumb in match: main.addDir(name, url, 864, thumb) else: match = re.compile( 'class="contentarchivetime">([^"]*)</div><div class="contentarchivetitle"><a href="([^"]*)" title=".+?">([^"]*)</a></div>' ).findall(link) for date, url, name in match: main.addDir(name, url, 864, '') paginate = re.compile( '="nextpostslink" rel="next" href="([^"]*)">»</a>').findall( link) if paginate: xurl = paginate[0] main.addDir('[COLOR blue]Next Page' + '[/COLOR]', xurl, 867, art + '/next2.png')
def SEARCH(murl = '',index=False): encode = main.updateSearchFile(murl,'Movies') if not encode: return False surl='http://megashare.li/index.php?search='+encode+'&movie=&x=0&y=0' link=main.OPENURL(surl) link=link.replace('\r','').replace('\n','').replace('\t','').replace(' ','') match=re.compile('class="item"><a href="([^"]*)"><img alt=".+?src="([^"]*)" /></a><div class="title"><a title="watch movie([^"]*)" href=".+?<div class="year"> ([^"]*)</div>').findall(link) dialogWait = xbmcgui.DialogProgress() ret = dialogWait.create('Please wait until Movie list is cached.') totalLinks = len(match) loadedLinks = 0 remaining_display = 'Movies loaded :: [B]'+str(loadedLinks)+' / '+str(totalLinks)+'[/B].' dialogWait.update(0, '[B]Will load instantly from now on[/B]',remaining_display) xbmc.executebuiltin("XBMC.Dialog.Close(busydialog,true)") for url,thumb,name,date in match: name=name.replace('-','').replace('&','').replace('acute;','') furl= MainUrl+url main.addInfo(name+'[COLOR blue] '+date +'[/COLOR]',furl,50,thumb,'','') loadedLinks = loadedLinks + 1 percent = (loadedLinks * 100)/totalLinks remaining_display = 'Movies loaded :: [B]'+str(loadedLinks)+' / '+str(totalLinks)+'[/B].' dialogWait.update(percent,'[B]Will load instantly from now on[/B]',remaining_display) if dialogWait.iscanceled(): return False dialogWait.close() del dialogWait exist = re.findall('<a href="([^"]*)" class="next">Next »</a>',link) if exist: main.addDir('[COLOR blue]Next Page ->[/COLOR]',MainUrl+url,20,art+'/next.jpg',index=index) xbmcplugin.setContent(int(sys.argv[1]), 'Movies')
def SEARCH(murl=''): encode = main.updateSearchFile(murl, 'Movies') if not encode: return False surl = MainUrl + '/search.php?key=' + encode + '&submit=' link = main.OPENURL(surl) link = link.replace('\r', '').replace('\n', '').replace('\t', '').replace(' ', '') match = re.compile( '<div class="movie_pic"><a href="([^"]+?)"[^>]+?>\s*?<img src="([^"]+?)"[^>]+?>.+?<a href[^>]+?>([^<]+?)</a></h1><div class=".+?">().*?Views: <span>(.+?)</span>.+?id=RateCount_.+?>(.+?)</span>.*?<li class="current-rating" style="width:(\d+?)px' ).findall(link) dialogWait = xbmcgui.DialogProgress() ret = dialogWait.create('Please wait until Movie list is cached.') totalLinks = len(match) loadedLinks = 0 remaining_display = 'Movies loaded :: [B]' + str( loadedLinks) + ' / ' + str(totalLinks) + '[/B].' dialogWait.update(0, '[B]Will load instantly from now on[/B]', remaining_display) xbmc.executebuiltin("XBMC.Dialog.Close(busydialog,true)") for url, thumb, name, genre, views, votes, rating in match: name = name.replace('-', '').replace('&', '').replace('acute;', '') furl = MainUrl + url main.addInfo( name + '[COLOR blue] Views: ' + views + '[/COLOR] [COLOR red]Votes: ' + votes + '[/COLOR] [COLOR green]Rating: ' + rating + '/100[/COLOR]', furl, 3, thumb, genre, '') loadedLinks = loadedLinks + 1 percent = (loadedLinks * 100) / totalLinks remaining_display = 'Movies loaded :: [B]' + str( loadedLinks) + ' / ' + str(totalLinks) + '[/B].' dialogWait.update(percent, '[B]Will load instantly from now on[/B]', remaining_display) if dialogWait.iscanceled(): return False dialogWait.close() del dialogWait exist = re.findall("<a href='search.php.?page=.+?'>Next</a>", link) if exist: r = re.findall( """>Next</a><a href='search.php.?page=([^<]+)&key=.+?'>Last</a>""", link) if r: main.addDir( '[COLOR blue]Page 1 of ' + r[0] + '[/COLOR]', 'http://www.movie25.so/search.php?page=2&key=' + encode, 9, art + '/next2.png') else: main.addDir( '[COLOR blue]Page 1[/COLOR]', 'http://www.movie25.so/search.php?page=2&key=' + encode, 9, art + '/next2.png') xbmcplugin.setContent(int(sys.argv[1]), 'Movies') main.GA("None", "Movie25-Search")
def SEARCH(url = ''): encode = main.updateSearchFile(url,'TV') if not encode: return False surl='http://videobull.to/?s=' + encode + '&x=0&y=0' link=main.OPENURL(surl) link=link.replace('\r','').replace('\n','').replace('\t','').replace(' ','') match=re.compile('class="cover"><a href="([^"]*)" rel="bookmark" title="([^"]*)"><img src="([^"]*)"').findall(link) if len(match) > 0: for url,name,thumb in match: main.addDir(name,url,864,thumb) else: match=re.compile('class="contentarchivetime">([^"]*)</div><div class="contentarchivetitle"><a href="([^"]*)" title=".+?">([^"]*)</a></div>').findall(link) for date,url,name in match: main.addDir(name,url,864,'') paginate=re.compile('="nextpostslink" rel="next" href="([^"]*)">»</a>').findall(link) if paginate: xurl=paginate[0] main.addDir('[COLOR blue]Next Page'+'[/COLOR]',xurl,867,art+'/next2.png')
def SEARCHTV(murl='', index=False): encode = main.updateSearchFile(murl, 'Shows') if not encode: return False surl = 'http://megashare.li/index.php?search=' + encode + '&tv=&x=0&y=0' link = main.OPENURL(surl) link = link.replace('\r', '').replace('\n', '').replace('\t', '').replace(' ', '') match = re.compile( 'class="item"><a href="([^"]*)"><img alt=".+?src="([^"]*)" /></a><div class="title"><a title="watch tv([^"]*)" href=".+?<div class="year"> ([^"]*)</div>' ).findall(link) dialogWait = xbmcgui.DialogProgress() ret = dialogWait.create('Please wait until Movie list is cached.') totalLinks = len(match) loadedLinks = 0 remaining_display = 'Movies loaded :: [B]' + str( loadedLinks) + ' / ' + str(totalLinks) + '[/B].' dialogWait.update(0, '[B]Will load instantly from now on[/B]', remaining_display) xbmc.executebuiltin("XBMC.Dialog.Close(busydialog,true)") for url, thumb, name, date in match: name = name.replace('-', '').replace('&', '').replace('acute;', '') furl = MainUrl + url main.addDirTE(name + '[COLOR blue] ' + date + '[/COLOR]', furl, 22, thumb, '', '', '', '', '') loadedLinks = loadedLinks + 1 percent = (loadedLinks * 100) / totalLinks remaining_display = 'Movies loaded :: [B]' + str( loadedLinks) + ' / ' + str(totalLinks) + '[/B].' dialogWait.update(percent, '[B]Will load instantly from now on[/B]', remaining_display) if dialogWait.iscanceled(): return False dialogWait.close() del dialogWait exist = re.findall('<a href="([^"]*)" class="next">Next »</a>', link) if exist: main.addDir('[COLOR blue]Next Page ->[/COLOR]', MainUrl + url, 15, art + '/next.jpg', index=index) xbmcplugin.setContent(int(sys.argv[1]), 'Movies')
def SEARCHTV(url=''): encode = main.updateSearchFile(url, 'TV') if not encode: return False surl = base_url + 'index.php?search=' + encode + '&tv=&x=0&y=0' link = main.OPENURL(surl) link = link.replace('\r', '').replace('\n', '').replace('\t', '').replace(' ', '') match = re.findall( '<a href="([^"]*)"><img alt="[^"]*" src="([^"]*)" /></a><div class="title"><a title="[^"]*" href="[^"]*">([^"]*)</a></div><ul class=\'star-rating\'><li class="current-rating" style="[^"]*"></li></ul><div class="item-genres"><a href="[^"]*">([^"]*)</a>', link) dialogWait = xbmcgui.DialogProgress() ret = dialogWait.create('Please wait until Movie list is cached.') totalLinks = len(match) loadedLinks = 0 remaining_display = 'Movies loaded :: [B]' + str( loadedLinks) + ' / ' + str(totalLinks) + '[/B].' dialogWait.update(0, '[B]Will load instantly from now on[/B]', remaining_display) for url, thumb, name, genre in match: name = name.replace('-', '').replace('&', '').replace('acute;', '').strip() main.addDir(name + '[COLOR blue] Genre: ' + genre + '[/COLOR]', base_url + url, 12, '', '') loadedLinks = loadedLinks + 1 percent = (loadedLinks * 100) / totalLinks remaining_display = 'Movies loaded :: [B]' + str( loadedLinks) + ' / ' + str(totalLinks) + '[/B].' dialogWait.update(percent, '[B]Will load instantly from now on[/B]', remaining_display) if (dialogWait.iscanceled()): return False dialogWait.close() del dialogWait nextpage = re.compile( '<a href="([^"]*)" class="next">Next »</a>').findall(link) for url in nextpage: main.addDir('Next Page >>', base_url + url, 1, art + '/next.jpg') xbmcplugin.setContent(int(sys.argv[1]), 'Movies') main.VIEWS()
def SEARCH(url=''): encode = main.updateSearchFile(url, 'Movies') if not encode: return False surl = 'http://www.filmesonlinegratis.net/?s=' + encode + '&s-btn=Buscar' link = main.OPEN_URL(surl) link = link.replace('\r', '').replace('\n', '').replace('\t', '').replace( ' ', '').replace('– ', ' - ') match = re.findall( 'title="([^"]*)">[^"]*</a></h2><divclass="capa"> <ahref="([^"]*)"><imgsrc="http://static.filmesonlinegratis.net/thumb.php[?]src=([^"]*)&w=135&h=185" alt="[^"]*" title="[^"]*" /></a> <spanclass="qualidade">([^"]*)</span>', link) dialogWait = xbmcgui.DialogProgress() ret = dialogWait.create('Please wait until Movie list is cached.') totalLinks = len(match) loadedLinks = 0 remaining_display = 'Movies loaded :: [B]' + str( loadedLinks) + ' / ' + str(totalLinks) + '[/B].' dialogWait.update(0, '[B]Will load instantly from now on[/B]', remaining_display) for name, url, thumb, quality in match: #main.addDirb(name+'[COLOR blue] Quality: '+quality+'[/COLOR]',str(url),8,thumb,'') main.addInfo(name + '[COLOR blue] Quality: ' + quality + '[/COLOR]', url, 8, thumb, '', '') loadedLinks = loadedLinks + 1 percent = (loadedLinks * 100) / totalLinks remaining_display = 'Movies loaded :: [B]' + str( loadedLinks) + ' / ' + str(totalLinks) + '[/B].' dialogWait.update(percent, '[B]Will load instantly from now on[/B]', remaining_display) if (dialogWait.iscanceled()): return False dialogWait.close() del dialogWait nextpage = re.compile('href="([^"]*)">\xc2\xbb</a>').findall(link) for url in nextpage: main.addDir('Next Page >>', base_url + url, 1, art + '/next.png') xbmcplugin.setContent(int(sys.argv[1]), 'Movies') main.VIEWS()
def SEARCH(mname,type): main.GA("None","SuperSearch") try: import Queue as queue except ImportError: import queue results = [] searchList=[] #mname=main.unescapes(mname) mname=main.removeColoredText(mname) if mname=='Search': mname='' encode = main.updateSearchFile(mname,type) if not encode: return False else: encode = encode.replace('%21','') if type=='Movies': q = queue.Queue() threading.Thread(target=iwatch,args=(encode,type,q)).start() results.append(q) q = queue.Queue() threading.Thread(target=movie25,args=(encode,type,q)).start() results.append(q) q = queue.Queue() threading.Thread(target=icefilms,args=(encode,type,q)).start() results.append(q) q = queue.Queue() threading.Thread(target=watchingnow,args=(encode,type,q)).start() results.append(q) q = queue.Queue() threading.Thread(target=mbox,args=(encode,type,q)).start() results.append(q) if selfAddon.getSetting('username') != '' and selfAddon.getSetting('password') != '': q = queue.Queue() threading.Thread(target=noobroom,args=(encode,type,q)).start() results.append(q) q = queue.Queue() threading.Thread(target=tubeplus,args=(encode,type,q)).start() results.append(q) q = queue.Queue() threading.Thread(target=tvrelease,args=(encode,type,q)).start() results.append(q) q = queue.Queue() threading.Thread(target=mynewvideolinks,args=(encode,type,q)).start() results.append(q) q = queue.Queue() threading.Thread(target=sceper,args=(encode,type,q)).start() results.append(q) q = queue.Queue() threading.Thread(target=fma,args=(encode,type,q)).start() results.append(q) q = queue.Queue() threading.Thread(target=scenesource,args=(encode,type,q)).start() results.append(q) else: encodewithoutepi = urllib.quote(re.sub('(?i)(\ss(\d+)e(\d+))|(Season(.+?)Episode)|(\d+)x(\d+)','',urllib.unquote(encode)).strip()) q = queue.Queue() threading.Thread(target=mbox,args=(encodewithoutepi,type,q)).start() results.append(q) q = queue.Queue() threading.Thread(target=watchseries,args=(encodewithoutepi,type,q)).start() results.append(q) q = queue.Queue() threading.Thread(target=iwatch,args=(encodewithoutepi,type,q)).start() results.append(q) q = queue.Queue() threading.Thread(target=icefilms,args=(encodewithoutepi,type,q)).start() results.append(q) q = queue.Queue() threading.Thread(target=tubeplus,args=(encodewithoutepi,type,q)).start() results.append(q) q = queue.Queue() threading.Thread(target=tvrelease,args=(encode,type,q)).start() results.append(q) q = queue.Queue() threading.Thread(target=mynewvideolinks,args=(encode,type,q)).start() results.append(q) if selfAddon.getSetting('rlsusername') != '' and selfAddon.getSetting('rlspassword') != '': q = queue.Queue() threading.Thread(target=rlsmix,args=(encode,type,q)).start() results.append(q) q = queue.Queue() threading.Thread(target=scenelog,args=(encode,type,q)).start() results.append(q) q = queue.Queue() threading.Thread(target=sceper,args=(encode,type,q)).start() results.append(q) q = queue.Queue() threading.Thread(target=scenesource,args=(encode,type,q)).start() results.append(q) for n in range(len(results)): searchList.extend(results[n].get()) dialogWait = xbmcgui.DialogProgress() ret = dialogWait.create('Please wait until Video list is cached.') totalLinks = len(searchList) loadedLinks = 0 remaining_display = 'Videos loaded :: [B]'+str(loadedLinks)+' / '+str(totalLinks)+'[/B].' dialogWait.update(0, '[B]Will load instantly from now on[/B]',remaining_display) searchList = sortSearchList(searchList,mname) wordsorg = set(encode.lower().split("%20")) if type == 'TV': wordsalt = set(encodewithoutepi.lower().split("%20")) for name,section,url,thumb,mode,dir in searchList: name = name.strip()+' [COLOR=FF67cc33]'+section+'[/COLOR]' name = name.replace('’',"'").replace('"','"') if type == 'TV' and (section == 'MBox' or section == 'WatchSeries' or section == 'iWatchOnline' or section == 'IceFilms' or section == 'TubePlus'): words = wordsalt else: words = wordsorg if words.issubset(name.lower().split()): if dir: if type=='Movies': main.addDirM(name,url,int(mode),thumb,'','','','','') else: if re.search('(?i)\ss(\d+)e(\d+)',name) or re.search('(?i)Season(.+?)Episode',name) or re.search('(?i)(\d+)x(\d+)',name): main.addDirTE(name,url,int(mode),thumb,'','','','','') else: main.addDirT(name,url,int(mode),thumb,'','','','','') else: if type=='Movies': main.addPlayM(name,url,int(mode),thumb,'','','','','') else: if re.search('(?i)\ss(\d+)e(\d+)',name) or re.search('(?i)Season(.+?)Episode',name) or re.search('(?i)(\d+)x(\d+)',name): main.addPlayTE(name,url,int(mode),thumb,'','','','','') else: main.addPlayT(name,url,int(mode),thumb,'','','','','') loadedLinks = loadedLinks + 1 percent = (loadedLinks * 100)/totalLinks remaining_display = 'Videos loaded :: [B]'+str(loadedLinks)+' / '+str(totalLinks)+'[/B].' dialogWait.update(percent,'[B]Will load instantly from now on[/B]',remaining_display) if dialogWait.iscanceled(): return False dialogWait.close() del dialogWait if type=='Movies': xbmcgui.Window(10000).setProperty('MASH_SSR_TYPE', '2') else: xbmcgui.Window(10000).setProperty('MASH_SSR_TYPE', '1') try: filelist = [ f for f in os.listdir(cachedir) if f.endswith(".fi") ] for f in filelist: os.remove(os.path.join(cachedir,f)) except:pass if not loadedLinks: xbmc.executebuiltin("XBMC.Notification(Super Search - "+encode.replace("%20"," ")+",No Results Found,3000)") xbmcplugin.endOfDirectory(int(sys.argv[1]), False, False) return False
def SEARCH(mname,type,libID=''): if libID=='': main.GA("None","SuperSearch") else: libName=mname if re.search('(?i).\s\([12][90]\d{2}\)',mname): mname = re.sub('(?i)^(.+?)\s\([12][90]\d{2}\).*','\\1',mname) elif re.search('(?i).\s[12][90]\d{2}',mname): mname = re.sub('(?i)^(.+?)\s[12][90]\d{2}.*','\\1',mname) mname = re.sub('(?i)\s\s+',' ',mname).strip() try: import Queue as queue except ImportError: import queue results = [] searchList=[] #mname=main.unescapes(mname) mname=main.removeColoredText(mname) if mname=='Search': mname='' encode = main.updateSearchFile(mname,type) if not encode: return False else: sources = [] encodeunquoted = urllib.unquote(encode) encode = re.sub('(?i)[^a-zA-Z0-9]',' ',encodeunquoted) encode = re.sub('(?i)\s\s+',' ',encode).strip() try: year = int(re.sub('(?i)^.+?\s\(?([12][90]\d{2})\)?.*','\\1',mname)) except: year = 0 encodeorg = encode encode = re.sub('(?i)^(.+?)\s\(?[12][90]\d{2}\)?.*','\\1',encode) encode = urllib.quote(encode) if type=='Movies': if selfAddon.getSetting('ssm_iwatch') != 'false': sources.append('iWatchOnline') q = queue.Queue() threading.Thread(target=iwatch,args=(encode,type,q)).start() results.append(q) if selfAddon.getSetting('ssm_movie25') != 'false': sources.append('Movie25') q = queue.Queue() threading.Thread(target=movie25,args=(encode,type,q)).start() results.append(q) if selfAddon.getSetting('ssm_icefilms') != 'false': sources.append('IceFilms') q = queue.Queue() threading.Thread(target=icefilms,args=(encode,type,q)).start() results.append(q) if selfAddon.getSetting('ssm_watchingnow') != 'false': sources.append('Watching Now') q = queue.Queue() threading.Thread(target=watchingnow,args=(encode,type,q)).start() if selfAddon.getSetting('ssm_filestube') != 'false': sources.append('FilesTube') q = queue.Queue() threading.Thread(target=filestube,args=(encode,type,q)).start() results.append(q) if selfAddon.getSetting('ssm_mbox') != 'false': sources.append('MBox') q = queue.Queue() threading.Thread(target=mbox,args=(encode,type,q)).start() results.append(q) if selfAddon.getSetting('ssm_yify') != 'false': sources.append('Yify') q = queue.Queue() threading.Thread(target=yify,args=(encode,type,q)).start() results.append(q) # if selfAddon.getSetting('ssm_noobroom') != 'false': # if selfAddon.getSetting('username') != '' and selfAddon.getSetting('password') != '': # sources.append('NoobRoom') # q = queue.Queue() # threading.Thread(target=noobroom,args=(encode,type,q)).start() # results.append(q) if selfAddon.getSetting('ssm_tubeplus') != 'false': sources.append('TubePlus') q = queue.Queue() threading.Thread(target=tubeplus,args=(encode,type,q)).start() results.append(q) if selfAddon.getSetting('ssm_tvrelease') != 'false': sources.append('TVRelease') q = queue.Queue() threading.Thread(target=tvrelease,args=(encode,type,q)).start() results.append(q) if selfAddon.getSetting('ssm_mynewvideolinks') != 'false': sources.append('MyNewVideoLinks') q = queue.Queue() threading.Thread(target=mynewvideolinks,args=(encode,type,q)).start() results.append(q) if selfAddon.getSetting('ssm_sceper') != 'false': sources.append('Sceper') q = queue.Queue() threading.Thread(target=sceper,args=(encode,type,q)).start() results.append(q) if selfAddon.getSetting('ssm_fma') != 'false': sources.append('FMA') q = queue.Queue() threading.Thread(target=fma,args=(encode,type,q)).start() results.append(q) if selfAddon.getSetting('ssm_scenesource') != 'false': sources.append('SceneSource') q = queue.Queue() threading.Thread(target=scenesource,args=(encode,type,q)).start() results.append(q) if selfAddon.getSetting('ssm_vip') != 'false': sources.append('VIP') q = queue.Queue() threading.Thread(target=vip,args=(encode,type,q)).start() results.append(q) # if selfAddon.getSetting('ssm_rls1click') != 'false': # sources.append('Rls1Click') # q = queue.Queue() # threading.Thread(target=rls1click,args=(encode,type,q)).start() else: encodetv = urllib.quote(re.sub('(?i)^(.*?((\ss(\d+)e(\d+))|(Season(.+?)Episode \d+)|(\d+)x(\d+))).*','\\1',urllib.unquote(encode))) encodewithoutepi = urllib.quote(re.sub('(?i)(\ss(\d+)e(\d+))|(Season(.+?)Episode)|(\d+)x(\d+)','',urllib.unquote(encodetv)).strip()) print encodetv if selfAddon.getSetting('sstv_mbox') != 'false': sources.append('MBox') q = queue.Queue() threading.Thread(target=mbox,args=(encodetv,type,q)).start() results.append(q) if selfAddon.getSetting('sstv_watchseries') != 'false': sources.append('WatchSeries') q = queue.Queue() threading.Thread(target=watchseries,args=(encodetv,type,q)).start() results.append(q) if selfAddon.getSetting('sstv_iwatch') != 'false': sources.append('iWatchOnline') q = queue.Queue() threading.Thread(target=iwatch,args=(encodetv,type,q)).start() results.append(q) if selfAddon.getSetting('sstv_pftv') != 'false': sources.append('PFTV') q = queue.Queue() threading.Thread(target=pftv,args=(encodetv,type,q)).start() results.append(q) if selfAddon.getSetting('sstv_icefilms') != 'false': sources.append('IceFilms') q = queue.Queue() threading.Thread(target=icefilms,args=(encodetv,type,q)).start() results.append(q) if selfAddon.getSetting('sstv_tubeplus') != 'false': sources.append('TubePlus') q = queue.Queue() threading.Thread(target=tubeplus,args=(encodetv,type,q)).start() results.append(q) if selfAddon.getSetting('sstv_tvrelease') != 'false': sources.append('TVRelease') q = queue.Queue() threading.Thread(target=tvrelease,args=(encodetv,type,q)).start() results.append(q) if selfAddon.getSetting('sstv_mynewvideolinks') != 'false': sources.append('MyNewVideoLinks') q = queue.Queue() threading.Thread(target=mynewvideolinks,args=(encodetv,type,q)).start() results.append(q) if selfAddon.getSetting('sstv_rlsmix') != 'false': if selfAddon.getSetting('rlsusername') != '' and selfAddon.getSetting('rlspassword') != '': sources.append('Rlsmix') q = queue.Queue() threading.Thread(target=rlsmix,args=(encodetv,type,q)).start() results.append(q) if selfAddon.getSetting('sstv_scenelog') != 'false': sources.append('SceneLog') q = queue.Queue() threading.Thread(target=scenelog,args=(encodetv,type,q)).start() results.append(q) if selfAddon.getSetting('sstv_sceper') != 'false': sources.append('Sceper') q = queue.Queue() threading.Thread(target=sceper,args=(encodetv,type,q)).start() results.append(q) if selfAddon.getSetting('sstv_scenesource') != 'false': sources.append('SceneSource') q = queue.Queue() threading.Thread(target=scenesource,args=(encodetv,type,q)).start() results.append(q) encodewithoutepi = urllib.unquote(encodewithoutepi) encode = urllib.unquote(encode) if libID=='': dialogWait = xbmcgui.DialogProgress() ret = dialogWait.create('Please wait. Super Search is searching...') loadedLinks = 0 remaining_display = 'Sources searched :: [B]'+str(loadedLinks)+' / '+str(len(results))+'[/B].' dialogWait.update(0,'[B]'+type+' Super Search - ' + encodeunquoted + '[/B]',remaining_display) totalLinks = len(results) whileloopps = 0 xbmc.executebuiltin("XBMC.Dialog.Close(busydialog,true)") while totalLinks > loadedLinks: for n in range(len(results)): try: searchList.extend(results[n].get_nowait()) loadedLinks += 1 percent = (loadedLinks * 100)/len(results) remaining_display = 'Sources searched :: [B]'+str(loadedLinks)+' / '+str(len(results))+'[/B].' dialogWait.update(percent,'[B]'+type+' Super Search - ' + encodeunquoted + '[/B]',remaining_display,sources[n] + ' finished searching') if dialogWait.iscanceled(): break; except: pass if dialogWait.iscanceled(): break; time.sleep(.1) ret = dialogWait.create('Please wait until Video list is cached.') totalLinks = len(searchList) loadedLinks = 0 remaining_display = 'Videos loaded :: [B]'+str(loadedLinks)+' / '+str(totalLinks)+'[/B].' dialogWait.update(0, '[B]Will load instantly from now on[/B]',remaining_display,' ') searchList = sortSearchList(searchList,mname) if not libID=='': for n in range(len(results)): searchList.extend(results[n].get()) searchList = sortSearchList(searchList,mname) import library t=threading.Thread(target=library.buildHostDB,args=(searchList,libID,libName)) t.start() t.join() else: encode = encodeorg if type == 'TV': wordsalt = set(encodewithoutepi.lower().split()) encode = urllib.unquote(encodetv) wordsorg = set(encode.lower().split()) for name,section,url,thumb,mode,dir in searchList: name = name.replace('’',"'").replace('"','"').strip() cname = re.sub('(?i)[^a-zA-Z0-9]',' ',name) try: cyear = int(re.sub('(?i)^.+?\s\(?([12][90]\d{2})\)?.*','\\1',cname)) except: cyear = 0 if year and not re.search('(?i)^.+?\s\(?([12][90]\d{2})\)?.*',cname): cname += ' ' + str(year) elif (cyear + 1) == year or (cyear - 1) == year: cname = cname.replace(str(cyear),str(year)) name = name +' [COLOR=FF67cc33]'+section+'[/COLOR]' if type == 'TV' and (section == 'MBox' or section == 'WatchSeries' or section == 'iWatchOnline' or section == 'IceFilms' or section == 'TubePlus'): words = wordsalt else: words = wordsorg if words.issubset(cname.lower().split()): if dir: if type=='Movies': main.addDirM(name,url,int(mode),thumb,'','','','','') else: if re.search('(?i)\ss(\d+)e(\d+)',name) or re.search('(?i)Season(.+?)Episode',name) or re.search('(?i)(\d+)x(\d+)',name): main.addDirTE(name,url,int(mode),thumb,'','','','','') else: main.addDirT(name,url,int(mode),thumb,'','','','','') else: if type=='Movies': main.addPlayM(name,url,int(mode),thumb,'','','','','') else: if re.search('(?i)\ss(\d+)e(\d+)',name) or re.search('(?i)Season(.+?)Episode',name) or re.search('(?i)(\d+)x(\d+)',name): main.addPlayTE(name,url,int(mode),thumb,'','','','','') else: main.addPlayT(name,url,int(mode),thumb,'','','','','') loadedLinks = loadedLinks + 1 percent = (loadedLinks * 100)/totalLinks remaining_display = 'Videos loaded :: [B]'+str(loadedLinks)+' / '+str(totalLinks)+'[/B].' dialogWait.update(percent,'[B]Will load instantly from now on[/B]',remaining_display) if dialogWait.iscanceled(): return False dialogWait.close() del dialogWait if type=='Movies': xbmcgui.Window(10000).setProperty('MASH_SSR_TYPE', '2') elif type == 'TV': xbmcgui.Window(10000).setProperty('MASH_SSR_TYPE', '1') try: filelist = [ f for f in os.listdir(cachedir) if f.endswith(".fi") ] for f in filelist: os.remove(os.path.join(cachedir,f)) except:pass if not loadedLinks: xbmc.executebuiltin("XBMC.Notification(Super Search - "+encode.replace("%20"," ")+",No Results Found,3000)") xbmcplugin.endOfDirectory(int(sys.argv[1]), False, False) return False
def SEARCH(murl="", index=False): encode = main.updateSearchFile(murl, "Movies") if not encode: return False surl = MainUrl + "/search.php?key=" + encode + "&submit=" link = main.OPENURL(surl) link = link.replace("\r", "").replace("\n", "").replace("\t", "").replace(" ", "") match = re.compile( '<div class="movie_pic"><a href="([^"]+?)"[^>]+?>\s*?<img src="([^"]+?)"[^>]+?>.+?<a href[^>]+?>([^<]+?)</a></h1><div class=".+?">().*?Views: <span>(.+?)</span>.+?id=RateCount_.+?>(.+?)</span>.*?<li class="current-rating" style="width:(\d+?)px' ).findall(link) dialogWait = xbmcgui.DialogProgress() ret = dialogWait.create("Please wait until Movie list is cached.") totalLinks = len(match) loadedLinks = 0 remaining_display = "Movies loaded :: [B]" + str(loadedLinks) + " / " + str(totalLinks) + "[/B]." dialogWait.update(0, "[B]Will load instantly from now on[/B]", remaining_display) xbmc.executebuiltin("XBMC.Dialog.Close(busydialog,true)") for url, thumb, name, genre, views, votes, rating in match: name = name.replace("-", "").replace("&", "").replace("acute;", "") furl = MainUrl + url if index == "True": main.addInfo( name + "[COLOR blue] Views: " + views + "[/COLOR] [COLOR red]Votes: " + votes + "[/COLOR] [COLOR green]Rating: " + rating + "/100[/COLOR]", furl, 21, thumb, genre, "", ) else: main.addInfo( name + "[COLOR blue] Views: " + views + "[/COLOR] [COLOR red]Votes: " + votes + "[/COLOR] [COLOR green]Rating: " + rating + "/100[/COLOR]", furl, 3, thumb, genre, "", ) loadedLinks = loadedLinks + 1 percent = (loadedLinks * 100) / totalLinks remaining_display = "Movies loaded :: [B]" + str(loadedLinks) + " / " + str(totalLinks) + "[/B]." dialogWait.update(percent, "[B]Will load instantly from now on[/B]", remaining_display) if dialogWait.iscanceled(): return False dialogWait.close() del dialogWait exist = re.findall("<a href='search.php.?page=.+?'>Next</a>", link) if exist: r = re.findall(""">Next</a><a href='search.php.?page=([^<]+)&key=.+?'>Last</a>""", link) if r: main.addDir( "[COLOR blue]Page 1 of " + r[0] + "[/COLOR]", "http://www.movie25.so/search.php?page=2&key=" + encode, 9, art + "/next2.png", index=index, ) else: main.addDir( "[COLOR blue]Page 1[/COLOR]", "http://www.movie25.so/search.php?page=2&key=" + encode, 9, art + "/next2.png", index=index, ) xbmcplugin.setContent(int(sys.argv[1]), "Movies")
def SEARCH(murl = '',index=False): encode = main.updateSearchFile(murl,'Movies') if not encode: return False surl=MainUrl+'/search.php?key='+encode+'&submit=' LISTMOVIES(surl, index)
def SEARCH(murl='', index=False): encode = main.updateSearchFile(murl, 'Movies') if not encode: return False surl = MainUrl + '/search.php?key=' + encode + '&submit=' LISTMOVIES(surl, index)