html-form-to-google-sheet: problem after submit
when I press submit I see this message:
{"result":"error","error":{}}
About this issue
- Original URL
- State: closed
- Created 2 years ago
- Comments: 29 (2 by maintainers)
when I press submit I see this message:
{"result":"error","error":{}}
If it’s still not working for somebody: Keep in mind that google uses your native language by default. Before doing the first intialSetup change the sheetName accordingly.
Mine was “Arkusz1”, I had to redo all of the steps with this change but after this it worked like a charm.
FIXED The headers for the spreadsheet are case-sensitive with the form name attribute. The headers do not need to be in order, but the name attribute must EXACTLY match with the header.
<input name="email" type="email" placeholder="Email" required> <input name="name" type="text" placeholder="Name" required>
PREVIOUSLY
“Unfortunately, I have this problem as well.”
Failed to load resource: the server responded with a status of 404 ()
Finaly i found what is the problem. Here -> https://github.com/levinunnink/html-form-to-google-sheet#3-run-the-initialsetup-function you must set “doPost” instead of “InitialSetup” and it will work
Another mistake that maybe some people could be doing has to do with the Deployments.
Try to test first your deployment: Deploy > Test Deployment
Copy the URL to your HTML code (<form method=“POST” action=“URL_Test”).
After testing, now you can do the Deploy as in the documentation. Otherwise, every time you change something in your script you has to do another deployment.
ajax code for not to redirect to another page. means saving from same page not to go next page