BorlandTalk.com Forum Index BorlandTalk.com
Borland discussion newsgroups
 
Archives   FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Response : 302 Moved Temporarly

 
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi Internet Winsock
View previous topic :: View next topic  
Author Message
fer
Guest





PostPosted: Thu Sep 29, 2005 6:37 pm    Post subject: Response : 302 Moved Temporarly Reply with quote



Hi

I post a value to a server. i get 302 response which is normal. But when i
use explorer it also gets 302 but also gets some html code back which i
can't.
What should i do.

my code is like this

Try
Plist.Clear ;
PList.Add('id=00001') ;
MHttp.Request.Referer := 'https://myserver.com' ;
Result.Text := MHttp.Post ('https://myserver.com/mypage.html', PList) ;
Except
End ;

Best regards



Back to top
Remy Lebeau (TeamB)
Guest





PostPosted: Thu Sep 29, 2005 7:51 pm    Post subject: Re: Response : 302 Moved Temporarly Reply with quote




"fer" <feriduntakis (AT) spyahoo (DOT) com> wrote


Quote:
I post a value to a server. i get 302 response which is normal. But when i
use explorer it also gets 302 but also gets some html code back which i
can't.

Yes, you can. If you have the HandleRedirect property set to True, TIdHTTP
automatically redirects itself to the new URL and then downloads the read
HTML. In the case where you don't have HandleRedirects set to True, then
Post() will throw an EIdHTTPProtocolException exception. The
EIdHTTPProtocolException.ErrorMessage property will contain any HTML that
the server provided with the 302 reply.


Gambit



Back to top
Display posts from previous:   
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi Internet Winsock All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2006 phpBB Group
SEO toolkit © 2004-2006 webmedic.