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

Re: [Ftpapi] How to retrieve http status of last request



Hello Scott,

I tested the beta. Both the httpStatus and payload on 40x are now returned as expected.

Thank you very much for this correction and your support for this great tool!

Best regards
Richard


Am Do., 23. Juli 2020 um 19:53 Uhr schrieb Scott Klement <sk@xxxxxxxxxxxxxxxx>:
Hi Richard,

Please get the beta copy of httpapi found here:
http://www.scottklement.com/httpapi/beta

With the update I put in there:

1) http_req() will continue to return -1.  This is necessary to prevent
breaking compatibility with other people's existing programs.

2) http_error() should now return the correct code (401) in the 2nd
parameter.

3) The response body should now be returned, as needed.


Please try it out and make sure it works properly for you. Then, let me
know.  I will not release it until I've heard from you.

-SK


On 7/22/2020 12:35 PM, Scott Klement wrote:
>
> Hi Richard,
>
> I don't remember why HTTPAPI skips reading the response body for 401
> or 407 codes.  It has always worked this way, and you're the first one
> to notice or complain.   Most people don't need anything from the
> response body for these codes, they simply ask the user for a userid
> and password and try again.
>
> So, unfortunately, I can't explain it in greater detail because I
> simply don't remember.  (This code was written 19 years ago.)
>
> When I have some time, I will change HTTPAPI so that it does return
> the response body.
>
> -SK
>
>
--
_______________________________________________
Ftpapi mailing list
Ftpapi@xxxxxxxxxxxxxxxxxxxxxx
http://scottklement.com/mailman/listinfo/ftpapi


--

--
Richard la Croix
Software Engineer

 

richard.lacroix@xxxxxxxxxxx
T +41 41 767 81 53

 

Hapimag AG | Sumpfstrasse 18
6312 Steinhausen | Schweiz
www.hapimag.com
    
Eingetragen: Handelsregister des Kantons Zug, Firmennummer/UID: CHE-101.391.790,
MWST.-Nr.: CHE-101.391.790 MWST, CEO: Hassan Kadbi



  P Please consider the environment before printing this email
 
 
-- 
_______________________________________________
Ftpapi mailing list
Ftpapi@xxxxxxxxxxxxxxxxxxxxxx
http://scottklement.com/mailman/listinfo/ftpapi