Reputation: 79288
Is there a way to make an $.ajax POST request:
Are there some HTTP headers to accomplish this? The goal would be to track statistics with minimal server and client request processing.
Upvotes: 4
Views: 1807
Reputation: 21175
If it is no problem in terms of security, and the amount of data you send is at maximum 2K minus the length of your URL, use a GET request instead. A GET request sends only one TCP packet, instead of two packets as a POST request does (first the header, then the data).
Upvotes: 1
Reputation: 57085
The server should return a HTTP/204 No Content response. That's as close as you can get.
Upvotes: 6