diff options
author | RaNaN <Mast3rRaNaN@hotmail.de> | 2009-05-20 13:05:21 +0200 |
---|---|---|
committer | RaNaN <Mast3rRaNaN@hotmail.de> | 2009-05-20 13:05:21 +0200 |
commit | 641cd8c63f4c3a96a9acf4d46450ab975b9c66cd (patch) | |
tree | a1bf0e74c3bde51d174bc0d154d1f88359437fbc /Plugins/RapidshareCom.py | |
parent | Modul struktur angelegt und request klasse eingefügt (diff) | |
download | pyload-641cd8c63f4c3a96a9acf4d46450ab975b9c66cd.tar.xz |
Neue Request Klasse eingebunden + ein paar Status Funktionen
Diffstat (limited to 'Plugins/RapidshareCom.py')
-rw-r--r-- | Plugins/RapidshareCom.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/Plugins/RapidshareCom.py b/Plugins/RapidshareCom.py index 6f81a9549..8adf89e25 100644 --- a/Plugins/RapidshareCom.py +++ b/Plugins/RapidshareCom.py @@ -12,6 +12,7 @@ from time import time class RapidshareCom(Plugin): def __init__(self, parent): + Plugin.__init__(self, parent) self.plugin_name = "Rapidshare.com" self.plugin_pattern = r"http://(?:www.)?rapidshare.com/files/" self.plugin_type = "hoster" @@ -46,7 +47,7 @@ class RapidshareCom(Plugin): """ gets the url from self.parent.url saves html in self.html and parses """ url = self.parent.url - html = urllib2.urlopen(url).read() + html = self.req.load(url) self.html[0] = html self.html_old = time() @@ -58,8 +59,8 @@ class RapidshareCom(Plugin): file_server_url = re.search(r"<form action=\"(.*?)\"", self.html[0]).group(1) #free user - free_user_encode = urllib.urlencode({"dl.start" : "Free"}) - self.html[1] = urllib2.urlopen(file_server_url, free_user_encode).read() + #free_user_encode = urllib.urlencode({"dl.start" : "Free"}) + self.html[1] = self.req.load(file_server_url, None,{"dl.start" : "Free"}) self.html_old = time() self.get_wait_time() |