Welcome Guest, Not a member yet? Register   Sign In
trying to access the message
#1

(This post was last modified: 12-22-2020, 04:26 PM by includebeer. Edit Reason: Added [code] tags for readability )

This is the object returned from the fusionAuth library. I am getting it in a variable called $result. 

Code:
FusionAuth\ClientResponse Object
(
    [errorResponse] => stdClass Object
        (
            [fieldErrors] => stdClass Object
                (
                    [user.email] => Array
                        (
                            [0] => stdClass Object
                                (
                                    [code] => [duplicate]user.email
                                    [message] => A User with email [[email protected]] already exists.
                                )

                        )

                )

        )

  I am trying to print out the message. I have tried this echo($result->errorResponse->fieldErrors->user.email[message]); and every other way I could think of. 
 I an getting: Message: Undefined property: stdClass::$user
What is the proper way to echo out the message field?
proof that an old dog can learn new tricks
Reply


Messages In This Thread
trying to access the message - by richb201 - 12-22-2020, 11:26 AM
RE: trying to access the message - by includebeer - 12-22-2020, 04:31 PM



Theme © iAndrew 2016 - Forum software by © MyBB