I searched the questions but there are answers everywhere to send parameters in the URL. In my case it will not work, because I have to send an array with a large number of elements and other params in the request. Because of this, I don't want to put it on the URL, just send it as request parameters. Is this correct? What query should I use instead of get? Please help me.
Asked
Active
Viewed 70 times
-3
-
4Try a `POST` request: https://stackoverflow.com/questions/6396101/pure-javascript-send-post-data-without-a-form – Mojo Allmighty Jun 17 '21 at 12:47
1 Answers
0
I suggest reading about the POST method, which is used to "submit an entity to the specified resource, often causing a change in state or side effects on the server"

Fadi
- 205
- 1
- 9
-
-
1
-
I do actually, if you're trying to send data to a server then you should use either POST or PUT (GET is for retrieving data), I personally have no experience with the latter. But you can read about the differences [here](https://stackoverflow.com/questions/630453/what-is-the-difference-between-post-and-put-in-http). – Fadi Jun 17 '21 at 13:16