本篇文章介绍的内容是关于php合并两个一维数组,现在分享给大家,有需要的朋友可以参考一下
<?php
$array1 = array( 0 => 'zero_a' , 2 => 'two_a' , 3 => 'three_a' );
$array2 = array( 1 => 'one_b' , 3 => 'three_b' , 4 => 'four_b' );
$result = $array1 + $array2 ;
var_dump ( $result ); ?>
相关推荐:
php合并数组函数array_merge()
以上就是php合并两个一维数组的详细内容。