Board index » delphi » IdHttp Post error "302 Object Moved"?
Asaf Goldman
![]() Delphi Developer |
Wed, 01 Sep 2004 21:16:20 GMT
IdHttp Post error "302 Object Moved"?
Hi,
I am trying to login through this URL procedure TForm1.Button3Click(Sender: TObject); Var aStream: TMemoryStream; Params: TStringStream; begin aStream := TMemoryStream.create; Params := TStringStream.create(''); IdHTTP1.Request.ContentType := 'application/x-www-form-urlencoded'; try Params.WriteString(URLEncode('mfn=' + 'asa...@hotmail.com' + '&')); Params.WriteString(URLEncode('iccid=' + '12345')); with IdHTTP1 do begin try IdHTTP1.Post('http://isend.cellcom.co.il/english/LoginCheck.asp', except on E: Exception do showmessage('Error encountered during POST: ' + E.Message); end; end; aStream.WriteBuffer(#0' ', 1); RichEdit1.Text := PChar(aStream.Memory); except end; end; After pressing the button I am getting an Error number 302 end richedit "<head><title>Object moved</title></head> <body><h1>Object Moved</h1>This object may be found <a " How can I overcome this problem? Thanks in advanced, Asaf |