totti93 Posted December 27, 2010 Report Share Posted December 27, 2010 import sysimport urlgrabberimport urlgrabber.progressdef readURL(URL): return urlgrabber.urlread(URL)def unescape(str): char = str.split("%") ret = "" for i in range(1, len(char)): ret += chr(int(char[i], 16)) return retdef getembedurl(URL): HTML = readURL(URL) EMBED = ["", "", ""] EMBED[0] = unescape(HTML[HTML.find("document.write(unescape('") + 25: HTML.find("')")]) EMBED[1] = HTML[HTML.find("')+'") + 4: HTML.find("'+unescape('")] EMBED[2] = unescape(HTML[HTML.find("'+unescape('") + 12: HTML.find("'))")]) EMBED = EMBED[0] + EMBED[1] + EMBED[2] return EMBED[EMBED.find('src="') + 5: EMBED.find('" frameborder="')]def getmp4url(URL): HTML = readURL(URL) return HTML[HTML.find('value="file=') + 12: HTML.find('&provider=')]def main(): URL = sys.argv[1] FILE_NAME = sys.argv[2] URL = getembedurl(URL) URL = getmp4url(URL) progress = urlgrabber.progress.text_progress_meter() urlgrabber.urlgrab(URL, FILE_NAME, progress_obj = progress)main()E scris in Python. Poate are ceva greseli... L-am facut in graba Cum se foloseste?python __main__.py <link> <nume_fisier>ex:python __main__.py http://serialepenet.ro/house_m_d/sezon_7/episod_1 houseS07E01.mp4Aveti nevoie de libraria "urlgrabber". Quote Link to comment Share on other sites More sharing options...
Depanatorul Posted December 27, 2010 Report Share Posted December 27, 2010 pai fa unu complet ca ar fii super Quote Link to comment Share on other sites More sharing options...
oauzor Posted December 27, 2010 Report Share Posted December 27, 2010 De ce nu incercati ceva de genul?https://addons.mozilla.org/en-US/firefox/addon/8174/ Quote Link to comment Share on other sites More sharing options...
g3oflo Posted December 27, 2010 Report Share Posted December 27, 2010 oauzor mc ma Quote Link to comment Share on other sites More sharing options...
adonisslanic Posted December 27, 2010 Report Share Posted December 27, 2010 Nu, mai bun e VideoDownloadHelper, tot addon de firefox https://addons.mozilla.org/en-US/firefox/addon/3006/ Quote Link to comment Share on other sites More sharing options...