Unable to POST new data using POST method


#1

I am able to send data using curl; however, when sending new data from my project code to website it fails. The POST method has been working until the last few days.There is a html page encoded in my serial monitor:

Capture

William


#2

Verified sending valid data. HTTP error code returned is 410.

William


#3

@lucid Error 410 means the link is completely gone/deleted.
What is your website url?


#4

Observations-weather.000webhostapp.com


#5

can you try again now?


#6

Still not accepting new data; here is screen capture:

First two GET requests are requests for local web server and unrelated to POST method; still returning 410.

William


#7

if it is completely gone; why can I bring up all the pages of the website?

Just checked again; same result, 410.

William


#8

the website work fine for me with no errors


#9

Problem is I send data by the POST method; php file receives the POST data and builds the Observations.html page every 15 minutes. php file is not receiving the new data updates. Data is being sent; just not received!

This has worked since Feb. of this year! Part of the message that is echoed back I see https://www.google-analytics.com/analytics.js list in echoed back info.

William


#10

Can you try it with POSTMAN?


#11

I am not familiar with POSTMAN. I have been successful with Curl. Article that describes what I have been doing with the POST method: POST method used This method is only working with curl. Again, my php code has previously been working since Feb. 2018.

Could it be a new security setting, as explained in the linked article?

William


#12

Have downloaded POSTMAN. How do I create a POST request? Never used POSTMAN.

William


#13

How to Use Postman to Manage and Execute Your APIs


#14

Why re-invent the wheel. This project was working; should work as there have been no changes to the string that gets sent,

This is the curl result:

Curl data in this screen capture is what is currently time stamped 04/13/2018, 02:19:38. Data on Observations web page is NOT from what was uploaded from the ESP8266; it would have been time stamped 04/13/2018 02:15:03, happens every 15 minute interval from the top of the hour.


#15

Problem was cause by copying an old version of my project that did not have the correct destination path, Project was sending to:website/BME280/php instead of website/php file.

My apologies for not finding this before turning to the forum; then finding the cause, was my coding of the destination path!.

Will mark this up as a learning experience.

Website is working correctly.