I have a JSONArray as shown below
{
    "output": [
        "a",
        "b",
        "c",
        "d",
        "e"
    ]
}
I need to find if "e" exists in the above array in php. Can someone help me out with this ?
$array = json_decode($json, true);
if (in_array('e', $array['output'])) {
    ...
}
                        If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With