I'm dealing with php array and I have proplem with get the index of parent array. Here I want to find parent index of title so I try find it by loop but I failed find index if the title is array. How I can get the parent index if the title is array
<?php
$Arr = [
[
"title" => ["news", "nasional", "internasional", "regional", "metropolitan", "sains", "pendidikan"],
"url" => "AAA",
],
[
"title" => ["seleb", "news"],
"url" => "BBB"
],
[
"title" => "travel",
"url" => "CCC"
]
];
foreach($Arr as $value) {
$key = array_search("seleb", array_column($Arr , 'title'));
echo $key; // should return index parent is [1]
}
?>