我已经用IDHTTP控件的post正确获取了cookie。如下并把他保存在IdCookieManager1控件里了如下:
procedure TForm2.BitBtn1Click(Sender: TObject);
var
temp:tstringlist;
b:string;
begin
form1.Memo1.Text:='';
temp:=tstringlist.Create;
temp.add('url=http://localhost/bbs/main.asp');
temp.Add('username=ziluobu');
temp.Add('userpass=******);
temp.add('xuansave=1');
temp.Add('Submit1= 登录 ');
b:=form1.idhttp1.Post('http://localhost/bbs/login.asp',temp);
form1.memo1.Text:=b;
form2.Hide;
end;由于其他页面要用到Cookie的。但是我就是不知道再用idhttp.get时怎样把保存在IdCookieManager1里的cookie带上,这样就能正确访问此页了。请前辈指点!