Welcome Guest, Not a member yet? Register   Sign In
Quick question - merging two or more arrays without reindexing
#6

[eluser]TheFuzzy0ne[/eluser]
OK, I think I've solved it.

Code:
print_r($arr1 + $arr2);

#Output:
Array
(
    [1] => val 1
    [2] => val 2
    [10] => val 10
    [11] => val 11
)

I'd still be interested to know what PHP function the + construct calls, though.


Messages In This Thread
Quick question - merging two or more arrays without reindexing - by El Forum - 06-02-2009, 06:21 AM



Theme © iAndrew 2016 - Forum software by © MyBB