How to resolve internal error - server connection terminated while posting content to URL
I am trying to POST content to URL using CURL. My code snippet is as follows curl_easy_setopt(curl_handle, CURLOPT_PROXY, "proxy.xyz.com:8080"); curl_easy_setopt(curl_handle, CURLOPT_PROXYUSERPWD, "uname:password"); curl_easy_setopt(curl_handle,CURLOPT_POSTFIELDS, jsonResult.c_str()); curl_easy_setopt(curl_handle, CURLOPT_CUSTOMREQUEST, "POST"); curl_easy_setopt(curl_handle, CURLOPT_URL, "url"); curl_easy_setopt(curl_handle, CURLOPT_VERBOSE, 1L); /* provide a buffer to store errors in */ curl_easy_setopt(curl_handle, CURLOPT_ERRORBUFFER, error); res = curl_easy_perform(curl_handle); if(res !=
0 upvotes
View original discussion ↗
Comments
Sign in or sign up to comment and upvote.
No comments yet.