Array ( [0] => rubix )
Array ( [0] => limo )
Array ( [0] => icecream )
I need to convert this array into following type. How can I do that? For example like this:
Array ( [0] => rubix [1] => schoolbag [3] => limo [4] => frezzer [5] => paper )
Array ( [0] => rubix )
Array ( [0] => limo )
Array ( [0] => icecream )
I need to convert this array into following type. How can I do that? For example like this:
Array ( [0] => rubix [1] => schoolbag [3] => limo [4] => frezzer [5] => paper )
array_merge() is an option if you want to combine arrays.
$array1 = array("id1" => "rubix ");
$array2 = array("id2" => "limo ", "id3" => "icecream ", "id4" => "frezzer ");
$array3 = array_merge($array1, $array2/*, $arrayN, $arrayN*/);