-3

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.

Weronika
  • 368
  • 3
  • 24

1 Answers1

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
  • So you don't advise using a POST method? – Weronika Jun 17 '21 at 13:04
  • 1
    No, you should absolutely use POST. – Johannes Mols Jun 17 '21 at 13:07
  • 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