I have an array, like this:
)array (
'date' => '2015-12-10T00:16:58+0000',
'from' =>
array (
'name' => 'Joe Bloggs',
'user_id' => 3220562,
),
'message' => ':ip=1.1.1.1',
)
And here's my code:
$string = var_export($h, true);
echo $string;
And finally, here's what I would like to achieve: I would like to export single strings from the array (for example I want to export 'message', and then I would get an output of ":ip=1.1.1.1").
I have tried things like $h['message'] and this doesn't work, so I'm just wondering what's the easiest / cleanest way to do this.
Any help would be greatly appreciated.