http-post

PHP + curl, HTTP POST sample code?

Can anyone teach me, preferable show some sample how to do a php + curl HTTP POST? I want to send data like, username=user1, password=passuser1, gender=1 etc to www.domain.com And I am expecting a response, e.g "result=OK". Thanks ...

Is it possible to use an HTTP PUT to submit form data?

Simple question: everyone knows you can POST data in a HTML form to the server, and the browser will handle serializing the data in the form. However, is it possible to do this using a PUT verb instead? Either through Javascript or some other means. ...

Safe Data serialization for Plain HTTP GET & POST communication

Hello Friends, I'm using the client's browser to submit HTTP request. For report generation the securityToken is submitted as POST, for report download the same token needs to be submitted by the user browser, this time using GET. What encoding would you recommend for the securityToken which actually represents encrypted data. I've t...

HTTP POST complex requests with .NET

I have a Web Service method developed using .NET 3.5 (VS2008) which expects a few strings (username, password, subject, file type) and a binary document coded in Base64. I enabled both SOAP and HTTP POST. While SOAP works perfectly, it is not possible to send HTTP POST requests. The server responses with "Server was unable to process re...

Sending an image via POST Multipart (HTTPRequest)

I'm trying to send an image to a server, using HTTP Post Multipart. Everything else is fine, I have all the boundrys set and stuff. But what do I have to do to the image before hand? Do I have to convert it to binary? Here is the header data from the header (using Fiddler). This is what I need to upload: -----------------------------7d...

Using Http Post to AddList() in Sharepoint

On a remote client, I'm trying to create a new list in a sharepoint site. Right now, I'm building a CAML string and sending it via http post to my sharepoint site. I've used this method to update list items and create dws folders, but I can't seem to get AddList to work. I get an error "Remove server returned error:NotFound." here is my...

Open source fuzz tool for fuzzing HTTP POST requests.

I am looking for an open source fuzz tool for fuzzing HTTP POST requests. Any ideas? ...

Struts and logging HTTP POST request body

I'm trying to log the raw body of HTTP POST requests in our application based on Struts, running on Tomcat 6. I've found one previous post on SO that was somewhat helpful, but the accepted solution doesn't work properly in my case. The problem is, I want to log the POST body only in certain cases, and let Struts parse the parameters from...

cURL + HTTP_POST, keep getting 500 error. Has no idea?

Okay, I want to make a HTTP_POST using cURL to a SSL site. I already imported the certificate to my server. This is my code: $url = "https://www.xxx.xxx"; $post = "";# all data that going to send $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_POST, true); curl_setopt($ch, CURLOPT_POSTFIELDS, $post); c...

How to retrieve the value passed in POST method?

Hi friends, I would like to retrieve the value from POST method. I know it’s possible to retrieve the GET method value - from query string. So how is it possible for POST method? Thanks, Praveen jayapal ...

.NET PostSubmitter sends backslashes

Hi, I'm using C# to send JSON to a PHP-Script, like this: string json = "{"; json += "\"prop\":\"some text\""; json += "}"; PostSubmitter post = new PostSubmitter(); post.Url = "http://localhost/synch/notein.php"; post.Type = PostSubmitter.PostTypeEnum.Post; post.PostItems.Add("note", json); post.Post(); Of course I'll have to escape...

MVC Multiple submit buttons on a array of objects

Hi, I've got a list of objects in an MVC view, each with a set of submit buttons - Move up, Move down and Remove. Using the answer from this question, I can get the button clicked - but I need to know which item it would be operating on. The problem comes from the fact the input's value attribute is passed back, I need more informatio...

Sending form in libcurl

i need to send a file to a webserver using libcurl. i saw one of the examples in the curl website and am trying to implement it. it is the postit2.c example. can someone tell me how i might extend this to be able to send username and password as well ...

User Agent doesn't work on POST data HttpWebRequest

This has been messing me up hard i have been trying to solve this problem and after writing a dummy app to check headers and pointing my code to it i notice HttpWebRequest will completely ignore my user agent when i POST data. Why? How do i solve this? ...

Getting content-type for a file in ObjectiveC

Hi All, How to get the Content-Type for any file in ObjectiveC ? I can then set the "Content-Type" header while sending the file to any web server. Thanks ...

ASMX Test page displays HTTP POST as option when viewed from local machine but not remotely?

The auto-generated test page displays HTTP POST as option when viewed from local machine but not remotely. Why? How do I get it to display HTTP POST as an option? ...

Support clicking a link, but sending a POST (vs GET) to the server, without Ajax?

I'm thinking this isn't exactly possible, but maybe I'm wrong. I'm simply torn between those who believe that only POST requests should modify data on the server and people that relax the rule and allow GET requests to modify data. Take this situation. Say you have a table, each row is a row in the database. I'd like to allow them to...

Wrapper class for HttpGet / Post in Java?

Hi, Sorry, I'm quite new to Java. I've stumbled across HttpGet and HttpPost which seem to be perfect for my needs, but a little long winded. I have written a rather bad wrapper class, but does anyone know of where to get a better one? Ideally, I'd be able to do String response = fetchContent("http://url/", postdata); where postdata...

Can I use rest-client to POST a binary file to HTTP without multipart?

I have tried to do the following, but the web-service is NOT REST and does not take multi-part. What do I do in order to POST the image? @response = RestClient.post('http://www.postful.com/service/upload', {:upload => { :file => File.new("#{@postalcard.postalimage.path}",'rb') } ...

HTTP: can GET and POST requests from a same machine come from different IPs?

I'm pretty sure I remember reading --but cannot find back the links anymore-- about this: on some ISP (including at least one big ISP in the U.S.) it is possible to have a user's GET and POST request appearing to come from different IPs. (note that this is totally programming related, and I'll give an example below) I'm not talking abo...