Supposing I have these arrays:
$group1= array('id' => '1','title' => 'Group 1','description' => 'This is group1');
$group2= array('id' => '2','title' => 'Group 2','description' => 'This is group2');
$group3= array('id' => '3','title' => 'Group 3','description' => 'This is group3');
How to combine them into one multidimensional array like this:
$groups=array(array('id' => '1','title' => 'Group 1','description' => 'This is group1'),array('id' => '2','title' => 'Group 2','description' => 'This is group2'),array('id' => '3','title' => 'Group 3','description' => 'This is group3'))
I have tried using array_map but it is not producing the array I need. Thanks.