-2
我动态形式部分正在与一个幸福添加重复的场,用于序列化这一点,我想两个或更多阵列的组合阵列,现在用两个阵列测试和我结合这两个这样的,如何组合两个多个数组?
$array1 = Array
(
[0] => Collect Invoices
[1439797510547] => Array
(
[0] => Bank Name
[1] => Invoices
)
[1] => Comment
);
$array2 = Array
(
[0] => repeatField
[1439797510547] => Array
(
[0] => selectBanks
[1] => text
)
[1] => textarea
);
$mixedArray = array_combine($array1,$array2);
/* Result is like this */
Array
(
[Collect Invoices] => repeatField
[Array] => Array
(
[0] => selectBanks
[1] => text
)
[Comment] => textarea
)
但我想这样的一个答案
Array
(
[Collect Invices] => repeatField
[1439797510547] => Array
(
[Bank Name] => selectBanks
[Invoices] => text
)
[Comment] => textarea
)
谁能帮我,提前please..thanks
你至今尝试过什么? –
你想要什么没有魔法。你需要循环并合并/合并需要的东西。 –
“银行名称”,“发票”,“评论”是常量名称字段吗?它与其他数组的值是否有直接联系? – Justinas