how get post data in php code example
Example: get post data in php javascript
if($json = json_decode(file_get_contents("php://input"), true)) {
$data = $json;
} else {
$data = $_POST;
}
if($json = json_decode(file_get_contents("php://input"), true)) {
$data = $json;
} else {
$data = $_POST;
}