[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: HTTPAPI http_url_post_raw application/x-www-form-urlencodedquestion



Sender: Scott Klement <sk@xxxxxxxxxxxxxxxx>

Hi Michael,

A few thoughts:

a) There was a problem like this in some older versions of HTTPAPI. (I think version 1.11 was the last one with the problem, but I'm not 100% sure). Please make sure you're running version 1.15.

b) The content-type field is simply converted to ASCII and sent to the server. HTTPAPI does not try to interpret it's contents, and doesn't do anything differently when you change it. However, the server may be using this field, and it may be sending something differently that could be confusing HTTPAPI? or vice-versa.

c) A debugging log might provide me with additional insight.

d) The best way for me to see what's going on is to tell me how to reproduce the problem. Unfortunately, the code you posted isn't enough information for me to take your program and run it.


On Mon, 10 Apr 2006, Michael wrote:


I am trying to use HTTPAPIR4 to read a web page but when I do with the content-type below the program hangs. If I send the default content-type then it deosn't hang, but doesn't return the correct result. The only thing to do is "go tcpadm" and kill the socket that is in a "close-wait" state, the program returns with the correct result.

rc = http_url_post_raw(Http + WebSite + cgiScript
           :%addr(szFormValue) :%len(%trimr(szFormValue))
                           :1 :%paddr('INCOMING') :10
           :'Mozilla 1.0' :'application/x-www-form-urlencoded');

If rc <> 1;
 msg = http_error;
 dsply msg;
EndIf;

szFormValue = 'HTMLVersion=5.0&loc=en_US&Requester=UPSHome&' +
'tracknum=' + %Trim(TrackingNo) + '&' +
'AgreeToTermsAndConditions=yes&ignore=&' +
'track=';

Thanks for any help!
Michael

-----------------------------------------------------------------------
This is the FTPAPI mailing list.  To unsubsribe from the list send mail
to majordomo@xxxxxxxxxxxxx with the body: unsubscribe ftpapi mymailaddr
-----------------------------------------------------------------------