我使用IdHttp1+IdSSLIOHandlerSocketOpenSSL1的方式来访问HTTPS网站。如果使用GET则可以返回页面内容,但是如果使用POST则提示Connection Closed Gracefully.不知道问题出在何处。
解决方案 »
- 怎么获取DLL模块的返回数据?
- sqlquery怎么传给tdbedit控件
- 怎样设计个程序可以打开fastReport创建的报表重新设计?
- treeview控件如何和文件关联啊?
- 一个小技巧问题:关于菜单的设计。请高手看一下
- 运行时出现的一个错误提示,请求帮助分析一下其出错原因
- perform(WM_CANCELMODE, 0, 0)请问这句什么作用?
- 用IDUDPServer控件发送UDP包,如果目的IP:PORT不存在,为何会导致该IDUDPServer再也无法接受UDP包?
- delphi真厉害。
- Delphi如何处理SMTP的密码?
- 如何利用delphi读取一卡通的信息
- delphi停靠问题~~急~~~
Outt := TMemoryStream.Create; PostData.WriteString(Format('username=%s', [Account]));
PostData.WriteString(Format('&password=%s', [Password]));
PostData.WriteString(Format('&service=%s', ['miniblog']));
PostData.WriteString(Format('&encoding=%s', ['utf-8']));
PostData.WriteString(Format('&gateway=%s', ['1']));
PostData.WriteString('&url='+httpapp.HTTPEncode('http://t.sina.com.cn/ajaxlogin.php?framelogin=1&callback=parent.sinaSSOController.feedBackUrlCallBack'));
PostData.WriteString(Format('&returntype=%s', ['META']));
PostData.WriteString(Format('&savestate=%s', ['7']));
PostData.WriteString(Format('&useticket=%s', ['0']));
m_http.HTTPOptions := []; m_http.Request.ContentType := 'application/x-www-form-urlencoded';
m_http.Request.Referer := 'http://t.sina.com.cn/login.php?url=http%3A%2F%2Ft.sina.com.cn%2F';
m_http.Post('https://login.sina.com.cn/sso/login.php', PostData, outt);
执行这段代码后,提示“Connection Closed Gracefully.”。