diff options
author | zoidberg10 <zoidberg@mujmail.cz> | 2011-11-22 00:26:08 +0100 |
---|---|---|
committer | zoidberg10 <zoidberg@mujmail.cz> | 2011-11-22 00:26:08 +0100 |
commit | 9378237ddc39f8ee96e7a3ddb9cc37ce487c5f4d (patch) | |
tree | 325aba4194c29ee7869f662e1b8f8b5015afd283 /module/plugins/hoster/BezvadataCz.py | |
parent | SimpleHoster fix (diff) | |
download | pyload-9378237ddc39f8ee96e7a3ddb9cc37ce487c5f4d.tar.xz |
fix filepost (#431), hellspy, ifolder, letitbit, change SimpleHoster patterns
Diffstat (limited to 'module/plugins/hoster/BezvadataCz.py')
-rw-r--r-- | module/plugins/hoster/BezvadataCz.py | 20 |
1 files changed, 6 insertions, 14 deletions
diff --git a/module/plugins/hoster/BezvadataCz.py b/module/plugins/hoster/BezvadataCz.py index 4c198d95f..f061fa2b5 100644 --- a/module/plugins/hoster/BezvadataCz.py +++ b/module/plugins/hoster/BezvadataCz.py @@ -17,29 +17,19 @@ """ import re -from module.plugins.internal.SimpleHoster import SimpleHoster, parseFileInfo -from module.network.RequestFactory import getURL - -def getInfo(urls): - result = [] - - for url in urls: - file_info = parseFileInfo(BezvadataCz, url, getURL(url, decode=True)) - result.append(file_info) - - yield result +from module.plugins.internal.SimpleHoster import SimpleHoster, create_getInfo class BezvadataCz(SimpleHoster): __name__ = "BezvadataCz" __type__ = "hoster" __pattern__ = r"http://(\w*\.)*bezvadata.cz/stahnout/.*" - __version__ = "0.21" + __version__ = "0.22" __description__ = """BezvaData.cz""" __author_name__ = ("zoidberg") __author_mail__ = ("zoidberg@mujmail.cz") - FILE_NAME_PATTERN = r'<p><b>Soubor: ([^<]+)</b></p>' - FILE_SIZE_PATTERN = r'<li><strong>Velikost:</strong> ([0-9.]+) ([kKMG]i?B)</li>' + FILE_NAME_PATTERN = r'<p><b>Soubor: (?P<N>[^<]+)</b></p>' + FILE_SIZE_PATTERN = r'<li><strong>Velikost:</strong> (?P<S>[0-9.]+) (?P<U>[kKMG])i?)</li>' FILE_OFFLINE_PATTERN = r'<title>BezvaData \| Soubor nenalezen</title>' DOWNLOAD_FORM_PATTERN = r'<form class="download" action="([^"]+)" method="post" id="frm-stahnoutForm">' @@ -50,4 +40,6 @@ class BezvadataCz(SimpleHoster): self.logDebug("Download form: %s" % url) self.download(url, post = {"stahnoutSoubor": "St%C3%A1hnout"}, cookies = True) + +getInfo = create_getInfo(BezvadataCz)
\ No newline at end of file |