I need have an array structured like so
Array
(
[id] =>
[name] =>
[description] =>
[table_id] =>
[records] => Array
(
[0] => Array
(
[id] =>
[table_id] =>
[created] => 2016-01-15T09:19:36-0700
[updated] =>
[created_by] =>
[updated_by] =>
[fields] => Array
(
[created] =>
[Delivery Date] =>
[Total Price Including Shipping] =>
[Enquiry Status] =>
[Equipment Booked 1] =>
[Equipment Booked 2] =>
[Equipment Booked 3] =>
[Equipment Booked 4] =>
[Equipment Booked 5] =>
[Equipment Booked 6] =>
[Surname] =>
)
)
)
[record_count] => 1
)
I need to extract the [created] field from the last element of the nested array in [records]. I've tried doing the following
$target_elems = $target.['record_count'];
//print_r($target_elems);
//echo $target_elems;
//echo $target.['records'].[$target_elems].['created'];
echo '<pre>'; print_r($target); echo '<pre/>';
bur I always get Array to String conversion error (commented lines have been tested obviously).
the only generated output is
ArrayArrayArrayArray