Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

I don't understand Objects

Status
Not open for further replies.

elck

Programmer
Apr 19, 2004
176
NL
Hi,
A class returns an object (MailResult).
I can print_r the result which looks like this:

Code:
stdClass Object
(
    [headers] => Array
        (
            [from stip@il.com wed dec 14 15] => 35:41 2005
            [received] => Array
                (
                    [0] =>  from 
                    [1] =>  by 
                    [2] =>  by 
                    [3] =>  from 
                )

            [domainkey-signature] =>  a=rsa-sha1; q=dns; ;   
            [message-id] =>  <0f3f01c600bb$a
            [reply-to] =>  "Stippen" <stipp
            [from] =>  "Stippen" <stipp
            [to] =>  "content" <cont
            [subject] =>  Fw: moeil
......

I know it's not very bright, but how can I use the seperate results?
I tried print MailResult[headers][received][0];
and print MailResult[headers][from];
But that's too simple apparently.



Thanks for your patience.
 
Thanks Kjarner,

I guess it's time I learned about these things!

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top