I have a function that takes an array as an parameter, for example:
$args = array(
"foo" => "value"
);
oneFunction( $args );
function oneFunction( $array ){
$default = array(
"foo" => "foo",
"bar" => "bar"
);
//mescla valores
$array = mesclaArrays($default, $array);
//nesse exemplo, a saída deve ser
//array(
// "foo" => "value",
// "bar" => "bar"
//);
}
Is there a native function for this or do I need to create my own?