Re: [fpc-pascal] Using fphttpclient to simulate web action sequence

2015-04-30 Thread Michael Van Canneyt
On Thu, 30 Apr 2015, leledumbo wrote: Just extract the and save the value of the Set-Cookie header ? I always store the cookies explicitly. If that's so, the current Cookies property implementation seems broken. I try to debug and indeed I found that each Set-Cookie line overrides the previo

Re: [fpc-pascal] Using fphttpclient to simulate web action sequence

2015-04-30 Thread leledumbo
> Just extract the and save the value of the Set-Cookie header ? > I always store the cookies explicitly. If that's so, the current Cookies property implementation seems broken. I try to debug and indeed I found that each Set-Cookie line overrides the previous if there are more than one Set-Cook

Re: [fpc-pascal] Using fphttpclient to simulate web action sequence

2015-04-30 Thread Michael Van Canneyt
On Wed, 29 Apr 2015, leledumbo wrote: If the problem disappears after you do a Free and Create of the http class, then it means something is left hanging after the call. If I Free and re-Create the class, how can I ensure the request header of subsequent requests contain the same cookies? I

Re: [fpc-pascal] Using fphttpclient to simulate web action sequence

2015-04-29 Thread leledumbo
> If the problem disappears after you do a Free and Create of the http class, then it means something is left hanging after the call. If I Free and re-Create the class, how can I ensure the request header of subsequent requests contain the same cookies? I need to maintain 2 cookie values (which

Re: [fpc-pascal] Using fphttpclient to simulate web action sequence

2015-04-29 Thread Michael Van Canneyt
On Wed, 29 Apr 2015, leledumbo wrote: I need to create some kind of bot for automatic testing against our web app. The following app target real online web application: {$mode objfpc}{$H+} uses {$ifdef unix} cthreads, {$endif} Classes,SysUtils,fphttpclient; procedure Log(http: TFPHTTPCl

[fpc-pascal] Using fphttpclient to simulate web action sequence

2015-04-29 Thread leledumbo
I need to create some kind of bot for automatic testing against our web app. The following app target real online web application: {$mode objfpc}{$H+} uses {$ifdef unix} cthreads, {$endif} Classes,SysUtils,fphttpclient; procedure Log(http: TFPHTTPClient); begin WriteLn('BEGIN *