what am i doing wrong here?

when i have only One result coming back this code works perfectly

```
$someObject = json_decode($data);
$id=$someObject->clips[0]->id;

```

but when i want to do a loop because i may get back 10 results this code is not working, i am sure i am missing something very simple here

```
$someObject = json_decode($data);
//var_dump($someObject);

foreach($someObject as $json){
   echo $json->clips[0]->id; 
}

```

EDIT:
this solution worked for anyone else who comes looking

```
foreach ($someObject->clips as $clip){
   echo $clip->id. "<br>";
 }

```

not sure how the other one answers the for loop issue i was having however.