Please don't shoot the noob. I've done a fair amount of research before asking this. I have an array that is being returned that looks like this:
array(1) {
[0]=>
object(stdClass)#7 (4) {
["id"]=>
string(1) "1"
["camp_name"]=>
string(11) "Refuel Camp"
["director_id"]=>
string(1) "1"
["camp_logo"]=>
string(23) "images/Refuel_Camp3.jpg"
}
}
Now do I echo out the "camp_name" so it displays "Refuel Camp"?
When I try to echo that value as
<?= $camps["camp_name"]; ?>
I get Undefined index: camp_name
When I do
<?= $camps->camp_name; ?>
I get Trying to get property of non-object
I don't understand how to get to the inner part of that array.