كيف أحصل على عنصر معين من رابط json ؟

السلام عليكم

لدي اشكال مع احد الاكواد،اريد من خلاله الحصول على جميع عناصر query ضمن

"default>trendingSearchesDays>trendingSearches>title>query

جربت هذه الصيغة لكنها لم تعطيني أي نتيجة

<?php
$url = 'http s://trends.google.com/trends/api/dailytrends?hl=en-US&tz=300&geo=US&ns=15';
$get = file_get_contents($url);
$get = substr($get , strpos($get , "{"));
echo $get['default']['trendingSearchesDays']['trendingSearches']['title']['title'];
?>

$data = json_decode(file_get_contents($url), true);
echo $data['default']['trendingSearchesDays'][0]['trendingSearches'][0]['title']['query'];
$query_list = [];
foreach ($data['default']['trendingSearchesDays'] as $day) {
    foreach ($day['trendingSearches'] as $search_item) {
        $query_list[] = $search_item['title']['query'];
    }
}
var_dump($query_list);

شكرا على ردك

النتيجة التي يعطيها الكود هي

array(0) { }
$data = file_get_contents($url);
$data = substr($data , strpos($data , "{"));

$data = json_decode($data, true);

@zakariamouhid‍ 

الخطأ

Warning: Invalid argument supplied for foreach() in /home/babaoghb/rand.babavive.com/api/gettags.php on line 8