i am having problem running doPost function when i blank data in spreadsheet, in this case "id" is equal to zero. the problem is in the variable "get last id" which is in "getLastRow()-1", after I remove "-1" which means only "getLastRow()", this function runs successfully. whatever it is, this tutorial really enriches my skills with self-taught background knowledge of JSON API. many thanks
It would be the best tutorial of it’s type if you could add search functionality to this. I hope you consider this and extend this tutorial to do so. Thank you 🙏
Hello great videos! My code was working, but now I get this error... "has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource. If an opaque response serves your needs, set the request's mode to 'no-cors' to fetch the resource with CORS disabled." any help??? I dowloaded the cors plugin but then get another error that relates to running html not json script
You are doing great will be waiting for your coming videos. The code shows an error (Paused in debugger, in Line (.then (res => res.json()) ). Will highly appreciate it if you reply.
Thanks bro I have used loop sending 2d array but it doesn't post all values. example of values, var info = [ {name:"Ahraf",age:40},{name:"sumon",age:36},{name:"Jhone",age:30} ];
in afterSubmit you were using 'e' for the event variable, but the code from Bootstrap was using 'event' to preventDefault/stopPropagation. might have been causing the validation issue.
you can call it whatever you want in parents afterSubmit(event) . I think if you just add the class "was-validated" to the "form" itself it will validate all fields, but it will also add that annoying green formatting for valid fields, which I don't really like.
How could we incorporate something like a PUT or a DELETE request with this. Usually I would make an endpoint that takes an Id but I don't think you can specific endpoints in app scripts, maybe I'm wrong. Could you pass parameters through the doPost and do it this way?
Great videos! I've learned a lot from both your channels. One thing I'm confused on, if I wanted to check if the required values were already present on the Google Sheet, how would I do that? With doGet?
Hi, your videos have been very helpful for me. I have really learned a lot in a very short time frame. At 9:30min of this video, you are talking about no-cors in fetch url. When i remove this, my program stops with an error saying i have to put no-cors in the mode. But when i put no-cors, the response received from the app script is blank and therefore i am getting http status as 0. I am using VS code and Live Server on client side to test. When i tested my app script response in Postman, i am getting the correct result. Hope you can help here on how to proceed. Thanks in advance.
Sorry for this confusion.. I just restarted my VS code session and suddenly everything is fine after i remove no-cors in the mode. This is very baffeling.
Hi! Thanks for the videos. The code works nicely on localhost but when I deply it to a web I get: Uncaught (in promise) TypeError: NetworkError when attempting to fetch resource. anyone managed to solve this?
It would be the best tutorial of it’s type if you could add search functionality to this. I hope you consider this and extend this tutorial to do so. Thank you 🙏