input type submit not working in ONLY chrome [clos

2019-08-04 02:12发布

问题:

I've seen several questions asked about simple

<input type="submit" />

buttons not working in chrome, but I still am yet to find a solution. there is no js/jq attached to that button or to the form's onsubmit. Furthermore, I say it's not working in chrome and not webkit because it is working in safari, as well as ie and ff.

has anyone found a definitive answer on how to deal with this bug?

EDIT: this got voted down for b* reasons so here is a screenshot of the chrome console throwing the error that led me to my fix.

i'll take my rep back tyvm :P

回答1:

ok, so i found what was causing my instance of this problem to crash. Using chrome's console, I noticed that I had incorrectly used an input, type=text, that was named 'size'. this was causing chrome to throw an error and not continue with the submit. I moved the input[name="size"] out of the form and it worked fine. i could have changed the name of that input box, but that would require me changing it in a lot of instances, and the ajax involved with that box didn't care if it was named size

lesson: chrome doesn't like input's named size

that is all