Im just posting single data value like this '{'email':'[email protected]'}'
php file
$var = json_decode($_POST,true);
echo json_encode($var["email"]);
at this stage i just want to return the email address to get it working buts its giving me this error:
json_decode() expects parameter 1 to be string, array given in C:\wamp\www\buyme\include\getemailaddress.php on line 4
line 4 is the first line in my code
all i want to be able todo is access the email value and return it back in json_encode($var["email"])