Small updates for NET_7 HTTP Client test

pull/262/head
Przemek Wirkus 2014-04-11 14:46:12 +01:00
parent f5420154a5
commit 581c8b4086
1 changed files with 2 additions and 2 deletions

View File

@ -39,14 +39,14 @@ int main()
{
bool result = true;
const char *url_httpbin_post = "http://httpbin.org/post";
HTTPMap map;
HTTPText text(http_request_buffer, BUFFER_SIZE);
HTTPMap map;
map.put("Hello", "World");
map.put("test", "1234");
printf("HTTP_POST: Trying to post data to '%s' ...\r\n", url_httpbin_post);
const int ret = http.post(url_httpbin_post, map, &text);
if (ret == 0) {
printf("HTTP_POST: Read %d chars ... [OK]\n", strlen(http_request_buffer));
printf("HTTP_POST: Read %d chars ... [OK]\r\n", strlen(http_request_buffer));
printf("HTTP_POST: %s\r\n", http_request_buffer);
}
else {