WC_Order_Item_Fee::get_name()
Get order item name.
Метод класса: WC_Order_Item_Fee{}
Хуков нет.
Возвращает
Строку
.
Использование
$WC_Order_Item_Fee = new WC_Order_Item_Fee(); $WC_Order_Item_Fee->get_name( $context );
- $context(строка)
- What the value is for. Valid values are 'view' and 'edit'.
По умолчанию: 'view'
Код WC_Order_Item_Fee::get_name() WC Order Item Fee::get name WC 8.7.0
public function get_name( $context = 'view' ) { $name = $this->get_prop( 'name', $context ); if ( 'view' === $context ) { return $name ? $name : __( 'Fee', 'woocommerce' ); } else { return $name; } }