diff options
author | mkaay <mkaay@mkaay.de> | 2011-02-05 21:30:49 +0100 |
---|---|---|
committer | mkaay <mkaay@mkaay.de> | 2011-02-05 21:30:49 +0100 |
commit | 4a0c988f61d2bf64d2758f8bab1d31bd7116f568 (patch) | |
tree | 70a519d61478ac9d38e121f4d18076f5a07b51df /module/plugins/hoster | |
parent | fixed database conversion (diff) | |
download | pyload-4a0c988f61d2bf64d2758f8bab1d31bd7116f568.tar.xz |
uploading.com premium
Diffstat (limited to 'module/plugins/hoster')
-rw-r--r-- | module/plugins/hoster/UploadingCom.py | 22 |
1 files changed, 17 insertions, 5 deletions
diff --git a/module/plugins/hoster/UploadingCom.py b/module/plugins/hoster/UploadingCom.py index 5843180a7..1f3889f0e 100644 --- a/module/plugins/hoster/UploadingCom.py +++ b/module/plugins/hoster/UploadingCom.py @@ -30,16 +30,18 @@ class UploadingCom(Hoster): __name__ = "UploadingCom"
__type__ = "hoster"
__pattern__ = r"http://(?:www\.)?uploading\.com/files/(?:get/)?[\w\d]+/?"
- __version__ = "0.1"
+ __version__ = "0.2"
__description__ = """Uploading.Com File Download Hoster"""
- __author_name__ = ("jeix")
- __author_mail__ = ("jeix@hasnomail.de")
+ __author_name__ = ("jeix", "mkaay")
+ __author_mail__ = ("jeix@hasnomail.de", "mkaay@mkaay.de")
def setup(self):
self.html = [None,None,None]
if self.account:
- self.req.canContinue = True
+ self.resumeDownload = True
+ self.multiDL = True
else:
+ self.resumeDownload = False
self.multiDL = False
def process(self, pyfile):
@@ -66,7 +68,17 @@ class UploadingCom(Hoster): self.download(url)
def handlePremium(self):
- pass
+ postData = {}
+ postData['action'] = 'get_link'
+ postData['code'] = re.search('code: "(.*?)",', self.html[0]).group(1)
+ postData['pass'] = 'undefined'
+
+ self.html[2] = self.load('http://uploading.com/files/get/?JsHttpRequest=%d-xml' % timestamp(), post=postData)
+ url = re.search(r'"link"\s*:\s*"(.*?)"', self.html[2])
+ if url:
+ return url.group(1).replace("\\/", "/")
+
+ raise Exception("Plugin defect.")
def handleFree(self):
self.code = re.search(r'name="code" value="(.*?)"', self.html[0]).group(1)
|