Hi!
How can I print an $_POST ?
Example: echo $_POST['data'];
This returns nothing...
Hi!
How can I print an $_POST ?
Example: echo $_POST['data'];
This returns nothing...
Your code is correct.
You can use either:
var_dump($_POST);
or
print_r($_POST);
to print out the entire POST array for debugging.
You can only show the values of keys that exist. array_keys()
returns an array containing the keys that exist in the array. If there is no output for a key despite the fact that the key exists then the array may contain an empty value for that key.