How can I trigger this function on submit?

eddietibbitts
New Member
2 0 0

Screenshot 2021-11-06 at 09.13.11.png

I'd like to trigger this function when the user inputs their code and hits submit. 

Where am I going wrong?

Thanks!

Eddie

Replies 2 (2)
eddietibbitts
New Member
2 0 0

I am getting the following error: 

q-bar-validate:1494 Uncaught ReferenceError: querycode is not defined
at HTMLInputElement.onclick (q-bar-validate:1494)

MichalKopec
Excursionist
29 5 4

It's likely because the function is defined after the <form> block. Try to move it before.