changing function in the theme
-
hi
i need to change somethings in this function
/**
* ————————————————————————————————
* Custom function for product title
* ————————————————————————————————
*/
if( ! function_exists( ‘woocommerce_template_loop_product_title’ ) ) {
function woocommerce_template_loop_product_title() {
echo ‘<h3 class=”product-title”>‘ . get_the_title() . ‘</h3>’;
}
}
on line 13 in /wp-content/themes/woodmart/inc/integrations/woocommerce/template-tags.php
how can i do that in child theme ?
Hi,
Just copy the whole function to the child theme functions.php file and do your changes.
Kind Regards
it is not working i copied to the child theme this
function woocommerce_template_loop_product_title() {
echo ‘<h3 class=”product-title”>‘ . get_the_title() . ‘</h3>’;
}
is it enough ?
Yes, it is enough for this customization.