- var_dump: documentation ( source)
- array_merge_recursive: documentation ( source)
<?php
$array1 = array(
'colors' => array(
'red',
'yellow',
'blue',
),
'shapes' => array(
'circle',
'square',
),
);
$array2 = array(
'colors' => array(
'green',
'orange',
),
'shapes' => array(
'triangle',
),
);
var_dump(array_merge_recursive($array1, $array2));