在我下面的数组中,提取我想要的数据的最佳方法是什么['rowid']
。我已经尝试过 foreach 和类似的东西,但我似乎无法得到它。
大批:
array(4) {
["b5cfec3e70d0d57ea848d5d8b9f14d61"]=> array(7) {
["rowid"]=> string(32) "b5cfec3e70d0d57ea848d5d8b9f14d61"
["id"]=> string(3) "232"
["qty"]=> string(1) "1"
["price"]=> string(2) "15"
["name"]=> string(13) " DVD"
["options"]=> array(4) {
["description"]=> string(43) " retail DVD for personal use only."
["image"]=> string(36) "d31e3bc3e820b7faef50a400f721125a.jpg"
["additional_info"]=> NULL
["attributes"]=> string(29) "a:1:{s:6:"Format";s:3:"PAL";}"
}
["subtotal"]=> int(15)
}
["eda80a3d5b344bc40f3bc04f65b7a357"]=> array(7) {
["rowid"]=> string(32) "eda80a3d5b344bc40f3bc04f65b7a357"
["id"]=> string(3) "267"
["qty"]=> string(1) "1"
["price"]=> string(4) "9.99"
["name"]=> string(3) "DVD"
["options"]=> array(4) {
["description"]=> string(0) ""
["image"]=> string(0) ""
["additional_info"]=> NULL
["attributes"]=> NULL
}
["subtotal"]=> float(9.99)
}
["total_items"]=> int(2)
["cart_total"]=> float(24.99)
}