in_array for Multidimensional array
foreach($taxonomy_tree as $item){

                   $taxonomy_item_family = (json_encode($item));

                    $string = '"id":"1"';

                   if (str_contains($taxonomy_item_family, $string)) {
                        dd($item);
                    }


                }
by Giorgi Ivanidze
2 years ago
PHP
array
0
Pro tip: use ```triple backticks around text``` to write in code fences