WC_Product_Variation::get_height
Returns the product height.
Method of the class: WC_Product_Variation{}
Hooks from the method
Returns
String.
Usage
$WC_Product_Variation = new WC_Product_Variation(); $WC_Product_Variation->get_height( $context );
- $context(string)
- What the value is for. Valid values are view and edit.
Default:'view'
WC_Product_Variation::get_height() WC Product Variation::get height code WC 10.6.2
public function get_height( $context = 'view' ) {
$value = $this->get_prop( 'height', $context );
// Inherit value from parent.
if ( 'view' === $context && empty( $value ) ) {
$value = apply_filters( $this->get_hook_prefix() . 'height', $this->parent_data['height'], $this );
}
return $value;
}