All Questions

273
votes
28answers
107691 views

When do you use POST and when do you use GET?

From what I can gather, there are three categories: Never use GET and use POST Never use POST and use GET It doesn't matter which one you use. Am I correct in assuming those three cases? If so, wh...
292
votes
11answers
613439 views

PHP + curl, HTTP POST sample code?

Can anyone show me how to do a php curl with an HTTP POST? I want to send data like this: username=user1, password=passuser1, gender=1 To www.domain.com I expect the curl to return a response lik...
623
votes
34answers
316255 views

How do you handle multiple submit buttons in ASP.NET MVC Framework?

Is there some easy way to handle multiple submit buttons from the same form? Example: <% Html.BeginForm("MyAction", "MyController", FormMethod.Post); %> <input type="submit" value="Send" /&g...
215
votes
15answers
332014 views

How to add parameters to HttpURLConnection using POST

I am trying to do POST with HttpURLConnection(I need to use it this way, can't use HttpPost) and I'd like to add parameters to that connection such as post.setEntity(new UrlEncodedFormEntity(nvp)); ...
449
votes
23answers
541514 views

How do you extract POST data in Node.js?

How do you extract form data (form[method="post"]) and file uploads sent from the HTTP POST method in Node.js? I've read the documentation, googled and found nothing. function (request, response) { ...
229
votes
3answers
250528 views

How to post data in PHP using file_get_contents?

I'm using PHP's function file_get_contents() to fetch contents of a URL and then I process headers through the variable $http_response_header. Now the problem is that some of the URLs need some data ...
158
votes
7answers
144559 views

How to POST raw whole JSON in the body of a Retrofit request?

This question may have been asked before but no it was not definitively answered. How exactly does one post raw whole JSON inside the body of a Retrofit request? See similar question here. Or is this...
94
votes
10answers
131677 views

ios Upload Image and Text using HTTP POST

Thanks for reading. I am new to iOS and I am trying to upload an Image and a text using multi-part form encoding in iOS. The curl equivalent is something like this: curl -F "param1=value1" -F "para...
73
votes
7answers
147562 views

Sending an HTTP POST request on iOS

I'm trying to send an HTTP Post with the iOS application that I'm developing but the push never reaches the server although I do get a code 200 as response (from the urlconnection). I never get a resp...
68
votes
7answers
142518 views

Send POST request with JSON data using Volley

I would like to send a new JsonObjectRequest request: I want to receive JSON data (response from server): OK I want to send JSON formatted data with this request to the server JsonObjectRequest re...

Previous Next