-1
I’m doing an Axios.post and sending an object with JSON.stringfy()
In my php file I gave var_dump in the reply and $POST returns an array like this:
array(1) ' ["{"plate":"","ano_model":"","ano_fabr":"","chassis":","Renavam":"","brand name":"",
with the print_r it comes like this:
[{"plate":"","ano_model":"","ano_fabr":"","chassis":"","Renavam":"","tag":""
But I can’t get the value of this array in my function, I’ve tried $body['board'] and nothing.. if anyone can help me.
Apparently you are not using json_decode (https://www.php.net/manualen/function.json-decode.php) when receiving data via post in PHP.
– Benilson
That’s not it, when I try to use Decode it says it’s not a string, just because I have an array, as shown above
– Raphael Villadouro
So, it’s to use in array elements.
– Benilson
How do you really get to your string? With print_r?
– adventistaam