ESP-01 wi-fi module, difficulty to send datas by POST Method.

Hello Everyone,

I have difficulty to send data from my ESP-01(micro wi-wi module):

  1. i created one post-data.php post web page for take data(device,temp,umid,pres) by method post and write data to DB.(i tested it usung another http-page formxpost2.html by one graphical form and post-data.php work fine and update my DB)

The obstacle most big (for me), is how send AT command by my ESP-01-Module to update db.

I wrote in this and other fourum i need send data using json format !!!

  1. I not understand if i need insert some json code in "post-data.php" or its enougth insert json string in AT command.




POST /api/cleanposting HTTP/1.1\r\\r\nAccept: application/json\r\nConnection: close\r\nContent-Length: 241\r\nContent-Type: application/json\r\n\r\n{\r\n"api_key":"tPmAT5Ab3j7F9",\r\n"value1":"device01",\r\n"value2":"22",\r\n"value3":"66",\r\n"value4":"1200",\r\n}\r\n\r\n

the module gime me errors in last AT command.

Can you show me right solution for my case (AT commands, .php page, any json code to insert where?)

Thank you in advance.