trixe98
trixe98

Reputation: 13

How to make a default woocommerce product title?

What I want to have is that every new product will have the default title like this: shoe Size 10 Because there will be add many products everyday it would be much easier to have that as a default product title. Does someone have a code for this or can someone help me out with this?

Upvotes: 1

Views: 293

Answers (2)

Alan Lee
Alan Lee

Reputation: 132

You can use "Secondary title plugin". Instructions on link below secondary title plugin

Upvotes: 1

Rahul Kr Daman
Rahul Kr Daman

Reputation: 413

Try This Method

add_product( 'the_title', 'product_title');
function product_title( $title, $id ) {
if ( is_shop() && get_post_type( $id ) === 'product' ) {
return ( $title); 
} else {
return $title;
}
}

Upvotes: 0

Related Questions