ignore hidden elements and submit buttons
This commit is contained in:
@@ -57,8 +57,10 @@ define([
|
|||||||
var id = uid();
|
var id = uid();
|
||||||
var type = getInputType($this);
|
var type = getInputType($this);
|
||||||
|
|
||||||
// ignore hidden elements
|
// ignore hidden inputs, submit inputs, and buttons
|
||||||
if (type === 'hidden') { return; }
|
if (['button', 'submit', 'hidden'].indexOf(type) !== -1) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
$this // give each element a uid
|
$this // give each element a uid
|
||||||
.data('rtform-uid', id)
|
.data('rtform-uid', id)
|
||||||
|
|||||||
Reference in New Issue
Block a user