summaryrefslogtreecommitdiffstats
path: root/module/plugins/hoster/SizedriveCom.py
diff options
context:
space:
mode:
authorGravatar GammaC0de <GammaC0de@users.noreply.github.com> 2015-05-05 19:49:39 +0200
committerGravatar GammaC0de <GammaC0de@users.noreply.github.com> 2015-05-05 19:49:39 +0200
commit439a9598c1d1db9efa64f8e11bd120d5e0b289ae (patch)
tree0860a5f2cdea5129136f65e81cd11017d7373b1d /module/plugins/hoster/SizedriveCom.py
parentFix https://github.com/pyload/pyload/issues/1351 (diff)
parent[SimpleHoster] Why Premium download fails? (diff)
downloadpyload-439a9598c1d1db9efa64f8e11bd120d5e0b289ae.tar.xz
Merge pull request #1 from pyload/stable
sync
Diffstat (limited to 'module/plugins/hoster/SizedriveCom.py')
-rw-r--r--module/plugins/hoster/SizedriveCom.py41
1 files changed, 41 insertions, 0 deletions
diff --git a/module/plugins/hoster/SizedriveCom.py b/module/plugins/hoster/SizedriveCom.py
new file mode 100644
index 000000000..3b9748fb6
--- /dev/null
+++ b/module/plugins/hoster/SizedriveCom.py
@@ -0,0 +1,41 @@
+# -*- coding: utf-8 -*-
+
+import re
+
+from module.plugins.internal.SimpleHoster import SimpleHoster, create_getInfo
+
+
+class SizedriveCom(SimpleHoster):
+ __name__ = "SizedriveCom"
+ __type__ = "hoster"
+ __version__ = "0.01"
+
+ __pattern__ = r'http://(?:www\.)?sizedrive\.com/[rd]/(?P<ID>\w+)'
+
+ __description__ = """Sizedrive.com hoster plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("GammaC0de", None)]
+
+
+ NAME_PATTERN = r'>Nome:</b> (?P<N>.+?)<'
+ SIZE_PATTERN = r'>Tamanho:</b>(?P<S>[\d.,]+) (?P<U>[\w^_]+)'
+ OFFLINE_PATTERN = r'ARQUIVO DELATADO POR'
+
+
+ def setup(self):
+ self.resumeDownload = False
+ self.multiDL = False
+ self.chunkLimit = 1
+
+
+ def handleFree(self, pyfile):
+ self.wait(5)
+ self.html = self.load("http://www.sizedrive.com/getdownload.php",
+ post={'id': self.info['pattern']['ID']})
+
+ m = re.search(r'<span id="boton_download" ><a href="(.+?)"', self.html)
+ if m:
+ self.link = m.group(1)
+
+
+getInfo = create_getInfo(SizedriveCom)