inet GET and POST not working correctly.

Hello guys, I’m using inet GET and POST functions for my project that send and receives data from a web server. But something is not working correctly, after successfull connection to internet via GPRS i get the : “NOT CONN” in console (see attachment)

This is the code I’m using.

String params;
    params.concat("parcelid=" + String(parcel_id));
    params.concat("&humidity=" + String(humidity_percent));
    char msg[1000];
    memset(msg, 0, sizeof(msg));
    inet.httpPOST(server, 80, "/api/post/sync.php", params.c_str(), msg, 1000);
    char* jsonResponse = strstr(msg, "{");

The library is also in the attachment.

It is essential for this project for GPRS connection to work flawlessly so i would appreciate your help.

Can anyone tell me what are possible reasons for connection failure?

Please, feel free to ask for more info if needed.

Thank you in advance. (58.9 KB)