Normally, cookies are managed by the application. It is not always that simple because of path and expiration. You can have a lot of cookies grabbed from one or even several URL while redirecting. So you should really write some manager code to have cookies somewhat persistant. That's why the event pass the cookie thru an event and do not store it in the component.
Note that you can derive your own HTTP component from ICS component and add the storage or manager you like. In my opinion, it is better to write a separate class for cookie management and link that class to your HTTP component. A cookie manager component would be a nice addon to ICS :-) -- Contribute to the SSL Effort. Visit http://www.overbyte.be/eng/ssl.html -- [EMAIL PROTECTED] http://www.overbyte.be ----- Original Message ----- From: "Frans van Daalen" <[EMAIL PROTECTED]> To: "ICS support mailing" <email@example.com> Sent: Saturday, April 21, 2007 10:33 AM Subject: [twsocket] Httpcli cookie > While the discussion for the urlencode on autorelocate is going nicely :-) > I > also have a small remark to make about the cookie property. > > Currently the following is done when a cookie is received > ----------------- > else if Field = 'set-cookie' then begin > bAccept := TRUE; > TriggerCookie(Data, bAccept); > end > ----------------- > > would it not be beter to save the recieved cookie somewhere in the httpcli > component? I believe that this cookie-property is the only received > property > that is not feed back into the component when recieved. > > Currently I handle this in the oncookie event but that means that I have > extra variables laying around for every httpcli component I use and i > really > not like that. It's a kind of weird that after a get or post I need to > access on variable to see the real returned cookie value. > > I have the code available so i can propose the change but would like to > see > some comments on the basic idea first > > Kind regards, > > Frans > > > -- > To unsubscribe or change your settings for TWSocket mailing list > please goto http://www.elists.org/mailman/listinfo/twsocket > Visit our website at http://www.overbyte.be -- To unsubscribe or change your settings for TWSocket mailing list please goto http://www.elists.org/mailman/listinfo/twsocket Visit our website at http://www.overbyte.be