Home Forums WoodMart support forum Product Price colors in Search Results are Not reflecting as SET in Adv Typogra Reply To: Product Price colors in Search Results are Not reflecting as SET in Adv Typogra

#349647

Luke Nielsen
Keymaster

Hello,

3. The below code change the default notification text of the WooCommerce, also you should add it to the functions.php file in your child theme.

if ( ! function_exists('wd_customizing_variable_product_message') ) {
    function wd_customizing_variable_product_message( $translated_text, $untranslated_text, $domain ) {
        if ($untranslated_text == 'Please select some product options before adding this product to your cart.') {
            $translated_text = __( 'Here goes your custom text', $domain );
        }
        return $translated_text;
    }

    add_filter( 'gettext', 'wd_customizing_variable_product_message', 97, 3 );
}

https://gyazo.com/aae15cf79f11a443a024653c5c405172

Unfortunately, this alert notification comes from WooCommerce so all we can do is change the default alert notification.

Kind Regards

  • This reply was modified 2 years, 10 months ago by Luke Nielsen.