社区
网络编程
帖子详情
WinInet库http请求的问题
fddddddddddd
2013-03-08 04:55:44
http://api.map.baidu.com/ag/coord/convert?from=0&to=4&mode=1&x=106.504468&y=29.590220
如何请求上面的url?
...全文
146
4
打赏
收藏
WinInet库http请求的问题
http://api.map.baidu.com/ag/coord/convert?from=0&to=4&mode=1&x=106.504468&y=29.590220 如何请求上面的url?
复制链接
扫一扫
分享
转发到动态
举报
写回复
配置赞助广告
用AI写文章
4 条
回复
切换为时间正序
请发表友善的回复…
发表回复
打赏红包
Yofoo
2013-03-09
打赏
举报
回复
明明是Get, 为啥用Post
fddddddddddd
2013-03-08
打赏
举报
回复
upupup
fddddddddddd
2013-03-08
打赏
举报
回复
HINTERNET hInternet,hConnect,hRequest; BOOL bRet;CString strResponse; hInternet = InternetOpen(_T("User-Agent"),INTERNET_OPEN_TYPE_PRECONFIG,NULL,NULL,0); hConnect = InternetConnect(hInternet,"api.map.baidu.com",80,NULL,_T("HTTP/1.1"),INTERNET_SERVICE_HTTP,0,0); //http://api.map.baidu.com/ag/coord/convert?from=0&to=4&mode=1&x=106.504468&y=29.590220 hRequest = HttpOpenRequest(hConnect,"POST","/ag/coord/convert?",_T("HTTP/1.1"),NULL,NULL,INTERNET_FLAG_RELOAD,0); bRet = HttpSendRequest(hRequest,NULL,0,"from=0&to=4&mode=1&x=106.504468&y=29.590220",strlen("from=0&to=4&mode=1&x=106.504468&y=29.590220")); while(TRUE) { char cReadBuffer[4096]; unsigned long lNumberOfBytesRead; bRet = InternetReadFile(hRequest,cReadBuffer,sizeof(cReadBuffer) - 1,&lNumberOfBytesRead); } 百度返回参数无效,如何正确填写?
jimette
2013-03-08
打赏
举报
回复
ping 连接!
HttpInterface:
Win
dows上C++封装的HTTP
库
,包含三种实现模式(
Win
Inet
、
Win
Http、socket)
更新记录2019-09-10(1)修复
Win
Inet
实现
库
中的若干bug(下载到缓存中数据不对、
http请求
返回字符串\0截断……);(2)
Win
Inet
&
Win
Http实现
库
支持HTTPS协议;(3)测试HTTPS下载、请求。2020-03-07(1)抽离出...
WNetWrap:
Win
Inet
wrapper - tiny
win
dows HTTPS library, no dependencies. 封装了
Win
Inet
的强大
http请求
库
WNetWrap 一个小型的,无依赖的
库
,使用进行C ++中的HTTP(S)请求。 这仅适用于针对
Win
dows的开发人员,他们需要轻量级的HTTPS解决方案而无需外部
库
(例如 。基本的HTTP GET请求# include < iostream># include " ...
wnetwrap:
Win
inet
包装器-简单的https
库
wnetwrap 一个小型
库
,可帮助使用
Win
Inet
在C ++中发出简单的HTTP(S)请求。 #基本HTTP GET请求#include <iostream>#include "wnetwrap.h"using namespace wrap;using namespace std;int main(){req my_request; //...
api实现
http请求
,支持post和get方法
涉及范围,delphi6基本控件界面控件,线程,
win
inet
api
库
文件为7z格式,号称宇宙中最强大的压缩格式,请自行去www.7-zip.org下载解压软件
使用大的 POST 请求 HttpSendRequestEx
4.转到项目设置对话框中,单击链接选项卡,然后添加到
Win
Inet
.lib"对象/
库
模块:"字段。 5.请确保配置 Visual C++,以便编译器和链接器将使用
Win
inet
.h 和
Win
inet
.lib 从 Internet 客户端 SDK。如果未能做到这...
网络编程
18,356
社区成员
64,214
社区内容
发帖
与我相关
我的任务
网络编程
VC/MFC 网络编程
复制链接
扫一扫
分享
社区描述
VC/MFC 网络编程
c++
c语言
开发语言
技术论坛(原bbs)
社区管理员
加入社区
获取链接或二维码
近7日
近30日
至今
加载中
查看更多榜单
社区公告
暂无公告
试试用AI创作助手写篇文章吧
+ 用AI写文章