我有一个这样的数组:
[0] => [basketball][player]
[1] => [basketball][threes][player]
[2] => [basketball][home][leaders][player]
[3] => [basketball][away][leaders][player]
我想将每个元素转换为对关联数组中某个元素的引用:
$post['basketball']['player']
$post['basketball']['threes']['player']
etc.
有没有办法自动将前者翻译成后者?如果是这样会超级方便,如果不是可能超级不方便,所以我希望有办法,但我不知道它可能是什么。