Is there any difference in network communication for HTTP GET and POST requests?
With GET, I understand that the entire request is sent in one go.
With POST, I think the initial request is sent, and then a second request is sent which sends all the parameters.
For example, assume that the latency between server and client is 500ms. What would be the total time for a GET vs POST call?
I tested this while monitoring in Wireshark.
I created a simple HTML form and toggled the method between GET and POST.
Consistently, I noticed that GET requests send one packet, while POST sends two.
Even when the form data is very small, the POST data is always sent in the second packet.
This suggests to me that POST would be more impacted by latency.
UPDATE 2011.07.05:
Here is the simple HTML form for POST:
Here is the POST version: