Sorry for the bad title, it's really hard to describe,
$x['is']['tall'] = 'yes';
$y['personal']['age'] = 30;
I have dynamic array keys, and I want to it append to another array key, the result is like
$main['profile']['is']['tall'] = 'yes';
$main['profile']['personal']['age'] = 30;
cause when I use json_encode I want to the structure like {"profile":{"is":{"tall":"yes"},"personal":{"age":30}}}
I don't know how to extend the array key like that.