Answer the question
In order to leave comments, you need to log in
Are there ready-made solutions for smart merging of associative arrays?
There is a config like this:
{
"name1": "...",
"name2": "...",
"name3": {
"name4": "...",
"name5": {
"name6": "..."
},
"name7": "..."
}
}
{
"name3": {
"name5": {
"name6": "123"
}
}
}
Answer the question
In order to leave comments, you need to log in
array_merge_recursive() will not work as expected with integer keys.
Therefore, you will have to write your own, look for a ready-made one, or even install the graze / array-merger package
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question