diff options
author | Walter Purcaro <vuolter@gmail.com> | 2015-02-16 10:46:28 +0100 |
---|---|---|
committer | Walter Purcaro <vuolter@gmail.com> | 2015-02-16 10:46:28 +0100 |
commit | ce1c2b6b05c08b669357947e61ae40efce7fc50f (patch) | |
tree | 0b5f7996960cf35c4eface53a89eba18a37519b7 /pyload/plugin/hoster/YibaishiwuCom.py | |
parent | Fix filename case (diff) | |
download | pyload-ce1c2b6b05c08b669357947e61ae40efce7fc50f.tar.xz |
module temp
Diffstat (limited to 'pyload/plugin/hoster/YibaishiwuCom.py')
-rw-r--r-- | pyload/plugin/hoster/YibaishiwuCom.py | 55 |
1 files changed, 0 insertions, 55 deletions
diff --git a/pyload/plugin/hoster/YibaishiwuCom.py b/pyload/plugin/hoster/YibaishiwuCom.py deleted file mode 100644 index f7640390f..000000000 --- a/pyload/plugin/hoster/YibaishiwuCom.py +++ /dev/null @@ -1,55 +0,0 @@ -# -*- coding: utf-8 -*- - -import re - -from pyload.utils import json_loads -from pyload.plugin.internal.SimpleHoster import SimpleHoster, create_getInfo - - -class YibaishiwuCom(SimpleHoster): - __name__ = "YibaishiwuCom" - __type__ = "hoster" - __version__ = "0.13" - - __pattern__ = r'http://(?:www\.)?(?:u\.)?115\.com/file/(?P<ID>\w+)' - - __description__ = """115.com hoster plugin""" - __license__ = "GPLv3" - __authors__ = [("zoidberg", "zoidberg@mujmail.cz")] - - - NAME_PATTERN = r'file_name: \'(?P<N>.+?)\'' - SIZE_PATTERN = r'file_size: \'(?P<S>.+?)\'' - OFFLINE_PATTERN = ur'<h3><i style="color:red;">哎呀!提取码不存在!不妨搜搜看吧!</i></h3>' - - LINK_PATTERN = r'(/\?ct=(pickcode|download)[^"\']+)' - - - def handleFree(self): - m = re.search(self.LINK_PATTERN, self.html) - if m is None: - self.error(_("LINK_PATTERN not found")) - url = m.group(1) - self.logDebug(('FREEUSER' if m.group(2) == 'download' else 'GUEST') + ' URL', url) - - res = json_loads(self.load("http://115.com" + url, decode=False)) - if "urls" in res: - mirrors = res['urls'] - elif "data" in res: - mirrors = res['data'] - else: - mirrors = None - - for mr in mirrors: - try: - url = mr['url'].replace("\\", "") - self.logDebug("Trying URL: " + url) - self.download(url) - break - except Exception: - continue - else: - self.fail(_("No working link found")) - - -getInfo = create_getInfo(YibaishiwuCom) |