If i knew the correct terms to search these would be easy to google this but im not sure on the terminology.
I have an API that returns a big object. There is one particular one i access via:
$bug->fields->customfield_10205[0]->name;
//result is [email protected]
There is numerous values and i can access them by changing it from 0 to 1 and so on
But i want to loop through the array (maybe thats not the correct term) and get all the emails in there and add it to a string like this:
implode(',', $array);
//This is private code so not worried too much about escaping
Would have thought i just do something like: echo implode(',', $bug->fields->customfield_10205->name);
Also tried echo implode(',', $bug->fields->customfield_10205);
And echo implode(',', $bug->fields->customfield_10205[]->name);
The output im looking for is: '[email protected],[email protected],[email protected]'
Where am i going wrong and i apologize in advance for the silly question, this is probably so newbie
var_dump()the value of$bug->fields->customfield_10205?[]andforeachbut not use array functions.