WC_Cart::get_items_needing_shipping()
Get only items that need shipping.
Method of the class: WC_Cart{}
No Hooks.
Return
Array
.
Usage
// protected - for code of main (parent) or child class $result = $this->get_items_needing_shipping();
Changelog
Since 3.0.0 | Introduced. |
WC_Cart::get_items_needing_shipping() WC Cart::get items needing shipping code WC 9.4.2
protected function get_items_needing_shipping() { return array_filter( $this->get_cart(), array( $this, 'filter_items_needing_shipping' ) ); }