我在PHP中有一个包含多个数组的数组,如下所示。
我希望能够抓住当时来自一个品牌的价值观。例如:抓住所有尺寸,所有材料和品牌号为55的所有颜色。看过如何从多维数组中获取值的教程,但我无法让它工作。
Array (
[0] => Array ( [size_1] => 7 [brand] => 45 )
[1] => Array ( [size_1] => 13 [brand] => 55 )
[2] => Array ( [material_1] => 7 [brand] => 45 )
[3] => Array ( [material_1] => 17 [brand] => 55 )
[4] => Array ( [material_2] => 15 [brand] => 45 )
[5] => Array ( [material_3] => 16 [brand] => 45 )
[6] => Array ( [material_4] => 8 [brand] => 45 )
[7] => Array ( [material_5] => 9 [brand] => 45 )
[8] => Array ( [material_5] => 11 [brand] => 86 )
[9] => Array ( [color_1] => 1093 [brand] => 55 )
[10] => Array ( [color_1] => 3064 [brand] => 54 )
[11] => Array ( [color_2] => 1687 [brand] => 55 )
[12] => Array ( [color_3] => 2297 [brand] => 55 )
[13] => Array ( [color_4] => 1280 [brand] => 55 )
[14] => Array ( [color_5] => 2822 [brand] => 55 )
)