A short description of a product is inserted in the meta description

[ad_1]

Hello @theevoq,

Thank you for contacting the support.

If you want to apply the Global Description only to the products, please replace the filter that you are using with this one:

add_action( 'rank_math/frontend/description', function( $generated ) {
if ( ! is_product() ) {
return $generated;
}

global $post;
$desc = RankMath\Helper::get_settings( "titles.pt_product_description" );
$desc = RankMath\Helper::replace_vars( $desc, $post );
return empty( $desc ) ? $generated : $desc;
});

Hope this helps. Let us know if you need any other assistance.

 

This site will teach you how to build a WordPress website for beginners. We will cover everything from installing WordPress to adding pages, posts, and images to your site. You will learn how to customize your site with themes and plugins, as well as how to market your site online.

Buy WordPress Transfer