I understand that, but my question was : how do i populate an array (or object) to use "echo $client->name;" format.
That means that i prefer to use that structure for reasons too long to explain....
Should I ignore the fact that you use the "->" object-deference operator, pay attention only to your text and the subject line of this thread and talk about arrays?
Or should I ignore all your text and the subject line of this thread, pay attention only to your use of the "->" object dereference operator and start talking about objects?
I really need to know, as the two things are different beasts and are not interchangeable.
If it's the former, you have my answer. If we're talking arrays, you're trying to use the wrong operator.
If the latter, insufficient data for a meaningful answer. What does the underlying object look like? What version of PHP are you running? Is the object variable private or protected? Was there a class method provided for assigning values to that variable?
Well,
I thought my question was pretty straightforward, but evidently it was not.
I was looking for a way to store data in php and be able to display with $whatever->whatever format. I thought (wrongly) this was probably in relation to some array manipulation, hence the subject line. I also thought (wrongly again) that some of the gurus here in tek-tips would have identified my needs even with a non correct subject line and, using a bit of flexibility, understood what my question was really about.
Fortunately I found out a way to do it myself, so my problem is now solved.
Thanks anyway, I know you dedicate a lot of your time for this board and that's something that is really appreciated.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.