Skip to content

Scrapy, a fast high-level web crawling & scraping framework for Python.

FormRequest: <input>'s default type must be text

Νικόλαος-Διγενής Καραγιάννης2d25eab0df4c
diff --git a/scrapy/http/request/form.py b/scrapy/http/request/form.py
index ea4bfd564..8ff394602 100644
--- a/scrapy/http/request/form.py
+++ b/scrapy/http/request/form.py
@@ -107,7 +107,7 @@ def _get_inputs(form, formdata, dont_click, clickdata, response):
inputs = form.xpath('descendant::textarea'
'|descendant::select'
- '|descendant::input[@type['
+ '|descendant::input[not(@type) or @type['
' translate(., "SUBMIT", "submit") != "submit"'
' and translate(., "IMAGE", "image") !="image"'
' and translate(., "RESET", "reset") != "reset"'