I have a form with id theForm which has the following div with a submit button inside:
theForm
Set the name attribute of your form to "theForm" and your code will work.
name
"theForm"