我有兩個不同的數組,我想用這兩個數組創建一個表。Laravel |兩個數組在foreach
但我不知道如何在Laravel Blade的一個foreach循環中實現這一點。
第一陣列是從外部API和第二陣列是一個Laravel收集我轉換爲一個數組與 - 指定者()
正如你可以看到兩個陣列具有10個元素,在我的表我想每行都有來自兩個數組的列。
array:10 [▼
0 => {#193 ▼
+"instanceID": "Ex1"
+"alias": null
+"displayName": "Ex1"
+"instanceHost": "exserver"
+"startMode": "automatic"
+"processID": 2960
+"status": "running"
+"startStopError": null
}
1 => {#194 ▶}
2 => {#195 ▶}
3 => {#196 ▶}
4 => {#197 ▶}
5 => {#198 ▶}
6 => {#199 ▶}
7 => {#200 ▶}
8 => {#201 ▶}
9 => {#202 ▶}
]
array:10 [▼
0 => array:8 [▼
"id" => 1
"name" => "Example"
"street" => "Exstreet 1"
"postalcode" => 1234
"city" => "Town"
"created_at" => "2015-11-05 16:18:02"
"updated_at" => "2015-11-05 16:53:58"
"status" => "Silver"
]
1 => array:8 [▶]
2 => array:8 [▶]
3 => array:8 [▶]
4 => array:8 [▶]
5 => array:8 [▶]
6 => array:8 [▶]
7 => array:8 [▶]
8 => array:8 [▶]
9 => array:8 [▶]
]
你能幫幫我嗎?
電賀 Wipsly