summaryrefslogtreecommitdiffstats
path: root/pyload/plugins/hoster/DataHu.py
diff options
context:
space:
mode:
Diffstat (limited to 'pyload/plugins/hoster/DataHu.py')
-rw-r--r--pyload/plugins/hoster/DataHu.py23
1 files changed, 13 insertions, 10 deletions
diff --git a/pyload/plugins/hoster/DataHu.py b/pyload/plugins/hoster/DataHu.py
index cacc1cae8..adadbfe5d 100644
--- a/pyload/plugins/hoster/DataHu.py
+++ b/pyload/plugins/hoster/DataHu.py
@@ -9,32 +9,35 @@ from pyload.plugins.internal.SimpleHoster import SimpleHoster, create_getInfo
class DataHu(SimpleHoster):
- __name__ = "DataHu"
- __type__ = "hoster"
- __version__ = "0.01"
+ __name__ = "DataHu"
+ __type__ = "hoster"
+ __version__ = "0.02"
- __pattern__ = r'http://(?:www\.)?data.hu/get/\w+'
+ __pattern__ = r'http://(?:www\.)?data\.hu/get/\w+'
__description__ = """Data.hu hoster plugin"""
- __authors__ = [("crash", None),
- ("stickell", "l.stickell@yahoo.it")]
+ __license__ = "GPLv3"
+ __authors__ = [("crash", None),
+ ("stickell", "l.stickell@yahoo.it")]
- FILE_INFO_PATTERN = ur'<title>(?P<N>.*) \((?P<S>[^)]+)\) let\xf6lt\xe9se</title>'
+ INFO_PATTERN = ur'<title>(?P<N>.*) \((?P<S>[^)]+)\) let\xf6lt\xe9se</title>'
OFFLINE_PATTERN = ur'Az adott f\xe1jl nem l\xe9tezik'
LINK_PATTERN = r'<div class="download_box_button"><a href="([^"]+)">'
- def handleFree(self):
+ def setup(self):
self.resumeDownload = True
- self.html = self.load(self.pyfile.url, decode=True)
+ self.multiDL = self.premium
+
+ def handleFree(self):
m = re.search(self.LINK_PATTERN, self.html)
if m:
url = m.group(1)
self.logDebug("Direct link: " + url)
else:
- self.parseError('Unable to get direct link')
+ self.error(_("LINK_PATTERN not found"))
self.download(url, disposition=True)