From: Brian Candler Date: 2007-05-25T01:56:17+09:00 Subject: Re: Problem with Net/HTTP On Fri, May 25, 2007 at 01:21:04AM +0900, Peer Allan wrote: > I am running into a serious problem with a custom library I am building > in Ruby. Basically I am writing a Ruby interface to a custom web > service that we have here at our company. The problem I am running into > is that I am posting the XML document to the service and it is > responding, but net/http is telling me there is no body > (response.body.empty? => true). Can you prove the response is there? The best way to do this is tcpdump -i eth0 -n -s0 -A tcp port 80 and look at the raw IP packets being sent by Ruby, and the response coming back. If you are on Windoze, then a sniffer like wireshark will do the trick. > I can't even find a way to see the raw response the > net/http received so I can check to see if it is just parsing it > incorrectly. There are two possible cases: Ruby is sending the request differently to PHP, or Ruby is parsing the response differently. Using tcpdump you should be able to find out (and compare what PHP is sending with what Ruby is sending) HTH, Brian.