First, I have tried to find solution within the source here but couldn't find what I am looking so posting as a new question. Thanks for your help
I want to convert Array to Object. Here is what I am getting output
Array
(
[0] => stdClass Object
(
[id] => 1
[username] => robustsolver
[first_name] => John
[last_name] => Smith
)
[1] => stdClass Object
(
[id] => 2
[username] => pickypacker
[first_name] => Peter
[last_name] => Packer
)
)
So if I want any column for all users than I have to write code $users[0]->first_name; which gives me only one item. But what I am looking is to use $users->first_name and this should return an array of all user's column (here is first_name)
Hope I have explain in better way. :S
Message: get_object_vars() expects parameter 1 to be object, array givenan array of objectsI was confused how to say it in words. Thanks again.. :)