-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