Witam!
Probuje się zalogować na rapidshare.com ale cos nie idzie... (podaje czesc kodu z logowaniem) np. cookie sie nie dodaja...
idHTTP.CookieManager.CookieCollection.Count
jest równy 0
var
IdHTTP: TIdHTTP;
StreamIn: TStringStream;
I: Integer;
begin
idHTTP:= TidHTTP.Create(nil);
idHTTP.CookieManager:=Form1.IdCookieManager1;
idHTTP.IOHandler:= Form1.IdSSLIOHandlerSocket1;
StreamIn:= TStringStream.Create('');
try
idHTTP.Request.ContentType:= mpfSource.RequestContentType;
StreamIn.WriteString('login=XXX&password=XXX');
idHTTP.Post('https://ssl.rapidshare.com/cgi-bin/premiumzone.cgi', StreamIn);
for i:=1 to idHTTP.CookieManager.CookieCollection.Count do
idHTTP.CookieManager.AddCookie(idHTTP.CookieManager.CookieCollection.Items[i-1].CookieText,
'http://www.rapidshare.com');
finally
idHTTP.Free;
StreamIn.Free;
end;
</delphi>
Po wyslaniu POST powinno byc w Response.RawHeaders:
Set-Cookie:user=blabla; domain=.rapidshare.com; path=/; expires=Wed, 13-Nov-2024 15:00:00 GMT
a nie ma tego...
Wie ktoś jak poprawnie sie zalogowac?