WC_Abstract_Legacy_Order::get_item_meta()publicWC 1.0

Deprecated from version 3.0.0. It is no longer supported and can be removed in future releases. It is recommended to replace this function with the same one.

Get order item meta.

Method of the class: WC_Abstract_Legacy_Order{}

No Hooks.

Return

Array|String.

Usage

$WC_Abstract_Legacy_Order = new WC_Abstract_Legacy_Order();
$WC_Abstract_Legacy_Order->get_item_meta( $order_item_id, $key, $single );
$order_item_id(mixed) (required)
-
$key(string)
-
Default: ''
$single(true|false)
(default: false)
Default: false

Changelog

Deprecated since 3.0.0

WC_Abstract_Legacy_Order::get_item_meta() code WC 8.9.0

public function get_item_meta( $order_item_id, $key = '', $single = false ) {
	wc_deprecated_function( 'WC_Order::get_item_meta', '3.0', 'wc_get_order_item_meta' );
	return get_metadata( 'order_item', $order_item_id, $key, $single );
}