maxatwork / form2js

Javascript library for collecting form data
http://maxatwork.github.com/form2js/
MIT License
640 stars 137 forks source link

Don't return disabled fields regardless of skipEmpty behavior #63

Closed kaiju closed 10 years ago

kaiju commented 10 years ago

Since browsers typically do not send disabled form elements on form submit, it's probably improper behavior to include them when constructing a structured object regardless of the value of skipEmpty.

Added a check for a node's disabled property that returns an empty array, thus preventing it from being added to formValues.