Documentation indicates sendBeacon sends its data via a HTTP POST request, but I cannot find the data sent.
Here is my javascript code : navigator.sendBeacon('log.php','Lost Data')
Browser logs indicate the "Lost Data" is the "request payload" for the request
In PHP the request is received but the $_POST variable seems to be an empty array.
I have sent from both Firefox & Chrome to both my local test server (windows) and to the live server (unix), all react the same.
What am I doing wrong?
How to access data sent by navigator.sendBeacon
How to access data sent by navigator.sendBeacon
Diplomacy, Trade & Conquest in the 4th Millenium
http://www.starlords3k.com
Re: How to access data sent by navigator.sendBeacon
Found the answer : The data from navigator.sendBeacon is in $HTTP_RAW_POST_DATA
Diplomacy, Trade & Conquest in the 4th Millenium
http://www.starlords3k.com