Reputation: 3
I need to read arrays saved in database to get specific variables.
Array
(
[0] => PHPMailer Object (
[From] => [email protected]
[FromName] => John Doe
)
)
I tried
echo "From".$row[0]["From"];
But it returns
From : P
Upvotes: 0
Views: 35
Reputation: 2644
PHPMailer
has a From
property. You should be able to access it like this:
echo("From: " . $row[0]->From);
Upvotes: 1
Reputation: 16446
From
and FromName
are object so you can get it using ->
. try:
echo "From".$row[0]->From;
Upvotes: 1