woocommerce_product_loop_title_classes
Show the product title in the product loop. By default this is an H2.
Usage
add_filter( 'woocommerce_product_loop_title_classes', 'wp_kama_woocommerce_product_loop_title_classes_filter' ); /** * Function for `woocommerce_product_loop_title_classes` filter-hook. * * @param $string * * @return */ function wp_kama_woocommerce_product_loop_title_classes_filter( $string ){ // filter... return $string; }
- $string
- -
Where the hook is called
woocommerce_product_loop_title_classes
woocommerce/includes/wc-template-functions.php 1179
echo '<h2 class="' . esc_attr( apply_filters( 'woocommerce_product_loop_title_classes', 'woocommerce-loop-product__title' ) ) . '">' . get_the_title() . '</h2>'; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped