0
如何访问以下结构中的“类型”项目?多维阵列 - 访问结构中的物品
下面是一个foreach输出,在变量$项目(从print_r($item);
输出)
Cartthrob_item_product Object (
[core:protected] => Cartthrob_core_ee Object (
[cart] => Cartthrob_cart Object (
[items:protected] => Array (
[3] => Cartthrob_item_product Object (
[item_options:protected] => Array (
[type] => product
)
)
)
)
)
)
'$ arr->核心 - > cart->项目[3] - > item_options [ '型']' –