<?php $arr1 = [ ['gross_value' => '100', 'quantity' => '5'], ['gross_value' => '200', 'quantity' => '6'] ]; $arr2 = [ ['item_title_id' => '1', 'order_id' => '3'], ['item_title_id' => '2', 'order_id' => '4'] ]; var_export( array_map('array_merge', $arr1, $arr2) ); echo "\n---\n"; var_export( array_merge_recursive($arr1, $arr2) );
You have javascript disabled. You will not be able to edit any code.