WC_Product::get_title PHP Method

get_title() public method

Get the product's title. For products this is the product name.
public get_title ( ) : string
return string
    public function get_title()
    {
        return apply_filters('woocommerce_product_title', $this->get_name(), $this);
    }

Usage Example

 protected function get_name(WC_Product $product)
 {
     if ($product->get_sku()) {
         $identifier = $product->get_sku();
     } else {
         $identifier = '#' . (isset($product->variation_id) ? $product->variation_id : $product->id);
     }
     return sprintf('%s - %s', $identifier, $product->get_title());
 }
All Usage Examples Of WC_Product::get_title
WC_Product