Is it possible to select data in a certain location, solely based on where it’s located in an array? I’ve tried slicing my array, but it shows information I still don’t want.
In that array, I would only like to have [match_player_stats][84947759][5947051]’s data show. But as you can see, there is another element in the same layer, which is why splicing doesn’t work. Basically, I want the first total element of [match_player_stats][84947759], in this case being [5947051]. Now don’t get me wrong, I could easily do this if the numbers were static, but these numbers change based on a matchID entered- which is why I need to select based on “location” (if you will).
Thanks!
To get the first element of an array, you can use array_shift. In your case: