PHP query array value

such as when querying BTC. Take out the BTC data inside.
when querying ETH. Just withdraw all the data in the ETH.

{
    "data": {
        "1": {
            "id": 1, 
            "name": "Bitcoin", 
            "symbol": "BTC", 
            "website_slug": "bitcoin", 
            "rank": 1, 
            "circulating_supply": 17040312.0, 
            "total_supply": 17040312.0, 
            "max_supply": 21000000.0, 
            "quotes": {
                "USD": {
                    "price": 8141.89, 
                    "volume_24h": 5978330000.0, 
                    "market_cap": 138740345870.0, 
                    "percent_change_1h": 0.14, 
                    "percent_change_24h": -1.98, 
                    "percent_change_7d": -7.2
                }
            }, 
            "last_updated": 1526636671
        }, 
        "1027": {
            "id": 1027, 
            "name": "Ethereum", 
            "symbol": "ETH", 
            "website_slug": "ethereum", 
            "rank": 2, 
            "circulating_supply": 99509087.0, 
            "total_supply": 99509087.0, 
            "max_supply": null, 
            "quotes": {
                "USD": {
                    "price": 683.134, 
                    "volume_24h": 2455830000.0, 
                    "market_cap": 67978040574.0, 
                    "percent_change_1h": 0.22, 
                    "percent_change_24h": -2.81, 
                    "percent_change_7d": -2.68
                }
            }, 
            "last_updated": 1526636958
        }, 
        "52": {
            "id": 52, 
            "name": "Ripple", 
            "symbol": "XRP", 
            "website_slug": "ripple", 
            "rank": 3, 
            "circulating_supply": 39189968239.0, 
            "total_supply": 99992233977.0, 
            "max_supply": 100000000000.0, 
            "quotes": {
                "USD": {
                    "price": 0.674545, 
                    "volume_24h": 353429000.0, 
                    "market_cap": 26435397126.0, 
                    "percent_change_1h": 0.14, 
                    "percent_change_24h": -3.24, 
                    "percent_change_7d": -4.18
                }
            }, 
            "last_updated": 1526636941
        }, 
        "1975": {
            "id": 1975, 
            "name": "ChainLink", 
            "symbol": "LINK", 
            "website_slug": "chainlink", 
            "rank": 100, 
            "circulating_supply": 350000000.0, 
            "total_supply": 1000000000.0, 
            "max_supply": null, 
            "quotes": {
                "USD": {
                    "price": 0.450519, 
                    "volume_24h": 1371140.0, 
                    "market_cap": 157681650.0, 
                    "percent_change_1h": 0.15, 
                    "percent_change_24h": -6.09, 
                    "percent_change_7d": -9.53
                }
            }, 
            "last_updated": 1526636956
        }
    }, 
    "metadata": {
        "timestamp": 1526636754, 
        "num_cryptocurrencies": 1593, 
        "error": null
    }
}
Mar.13,2021

$arr = $arr['data'];

$arr1 = array_filter($arr, function ($item){
    return $item['symbol'] == 'BTC';
});
var_dump($arr1);

function getData($type) {
  $data = obj["data"];
  foreach($data as  $item) {
    if($item['symbol'] == $type) {
       return $item;
    }
  }
}
$btcData = getData("BTC");
MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1b3c20c-2b650.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1b3c20c-2b650.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?