// httpPost.cpp : Defines the entry point for the console application.
//
#include "stdafx.h"
#include "stdio.h"
#include <time.h>
#include <WinSock2.h>
#include <cstringt.h>
#pragma comment(lib, "Ws2_32.lib")
char* SendHttpRequest(char* weburl, char* url , char* detectorId ,char* JsonData);
int main(int argc, char* argv[])
{
char* JsonData = "[{\"a\":\"b\"}]";
char weburl[] = "www.test.com:8081";
char* url = "/post";
char* Id = "aaa";
char* re = SendHttpRequest(weburl,url, Id, JsonData);
printf
C++ socket发送POST请求
最新推荐文章于 2024-06-04 15:32:31 发布