I am posting to a php script via jQuery:
$.post('http://*****.php', {'clicked':'true'}, 'json');
Looking at the post data, it responds with:
Request URL:http://*****.php
Request Method:POST
Status Code:200 OK
The Form Data in the headers looks like:
clicked:true
When I attempt to retrieve the POST data on my PHP script via:
var_dump($_POST);
I get an empty array:
array(0) { }
However, when playing around with the command line, I can successfully view the post data from the response when I do:
wget --post-data 'clicked=true' http://****.php
The successful response with wget is:
array(1) {
["name"]=>
string(4) "test"
}
I have been unable to figure it out... and it's not my HTACCESS file. Also, GET requests work just fine. I'm assuming my jQuery POST is wrong, but don't know what it could be - it comes directly from the jQuery docs.