WordPress at Your Fingertips
function is not described

WC_Product::get_price_html() public WC 1.0

Returns the price in html format.

{} It's a method of the class: WC_Product{}

Return

String.

Usage

$WC_Product = new WC_Product();
$WC_Product->get_price_html( $deprecated );
$deprecated(string)
Deprecated param.
Default: ''

Code of WC_Product::get_price_html() WC 5.8.0

public function get_price_html( $deprecated = '' ) {
	if ( '' === $this->get_price() ) {
		$price = apply_filters( 'woocommerce_empty_price_html', '', $this );
	} elseif ( $this->is_on_sale() ) {
		$price = wc_format_sale_price( wc_get_price_to_display( $this, array( 'price' => $this->get_regular_price() ) ), wc_get_price_to_display( $this ) ) . $this->get_price_suffix();
	} else {
		$price = wc_price( wc_get_price_to_display( $this ) ) . $this->get_price_suffix();
	}

	return apply_filters( 'woocommerce_get_price_html', $price, $this );
}