summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar GamaC0de <nitzo2001@yahoo.com> 2016-03-22 12:56:51 +0100
committerGravatar GamaC0de <nitzo2001@yahoo.com> 2016-03-22 12:56:51 +0100
commit9f9ade0d45f0159ff203087079bc8167ad9dfd7f (patch)
treea8e881ab5292f6c1f68144b62fb360a9d8f78fef
parent[CryptCat] Update (diff)
downloadpyload-9f9ade0d45f0159ff203087079bc8167ad9dfd7f.tar.xz
[misc] revert https://github.com/pyload/pyload/commit/e5b69006811275b28a282c053ad3e851e4a13cab
-rw-r--r--module/plugins/internal/misc.py15
1 files changed, 6 insertions, 9 deletions
diff --git a/module/plugins/internal/misc.py b/module/plugins/internal/misc.py
index 911359548..e2ab775de 100644
--- a/module/plugins/internal/misc.py
+++ b/module/plugins/internal/misc.py
@@ -38,7 +38,7 @@ except ImportError:
class misc(object):
__name__ = "misc"
__type__ = "plugin"
- __version__ = "0.31"
+ __version__ = "0.32"
__status__ = "stable"
__pattern__ = r'^unmatchable$'
@@ -755,17 +755,14 @@ def parse_html_form(attr_str, html, input_names={}):
for inputtag in re.finditer(r'(<(input|textarea|button).*?>)([^<]*(?=</\2)|)',
re.sub(re.compile(r'<!--.+?-->', re.I | re.S), "", form.group('CONTENT')),
re.I | re.S):
+
name = parse_html_tag_attr_value("name", inputtag.group(1))
if name:
- if inputtag.group(2).lower() == "button":
- if parse_html_tag_attr_value("type", inputtag.group(1)).lower() == "submit":
- inputs[name] = ""
+ value = parse_html_tag_attr_value("value", inputtag.group(1))
+ if not value:
+ inputs[name] = inputtag.group(3) or ""
else:
- value = parse_html_tag_attr_value("value", inputtag.group(1))
- if not value:
- inputs[name] = inputtag.group(3) or ""
- else:
- inputs[name] = value
+ inputs[name] = value
if not input_names:
#: No attribute check