Don't miss the chance! Use Coupon: black30 on checkout page to get 30% discount on any plugins.Buy Now!
Public Ticket #2919

Problem with discount after price when selecting variation.

Viktor Veverka

Hello! 

I have PRO and I am facing with problem, when is no selected any variation price is shown by your plugin after regular price. But when I select variation it goes again before regular price. How I can set  it to be same as your plugin?

And second question is about CSS of sale badge, can you provide me CSS string for editing? I can do a code for color, font etc… but I need to only identify class for shop and product page (globally)

My domain where you can look directly used on product: https://matracealmero.cz/obchod/pacific/

Thanks for help!

wpx

wpx

Hi Viktor,

I hope you are doing well today.

How I can set  it to be same as your plugin?

Unfortunately, when you select a variation that price is processed by WooCommerce. We just display the WooCommerce processed price HTML. Our plugin displays the discount badge for the initial price when you just land on your single product page.

And second question is about CSS of sale badge, can you provide me CSS string for editing?

Yes, sure, here is the selector:

span.vpd-discount-badge

Here is a sample CSS:

span.vpd-discount-badge {
background-color: blue;
}

You can write your own CSS using the above selector. We will also add a feature to change the color of the badge in our coming version.

Best Regards

Viktor Veverka

Viktor Veverka

Thanks, and can i get one more thing?

How i change that "11% off" in to my language as "11% sleva" without using Loco Translator.

Thanks!

wpx

wpx

Hi Viktor,

Please add the following snippet using the Code Snippets plugin or, add the following snippet inside your child theme's functions.php:

add_filter( 'vpd_discount_suffix', function( $default ){
$default = __(' sleva', 'variation-price-display-pro');
return $default;
});

Note: It is recommended to add the Custom Code to the child theme’s functions.php file, to avoid any data loss while updating the Parent Theme.

We get excited & honored when you use our plugin on your site.

If you found my support helpful, could you please leave your valuable review here: https://wordpress.org/support/plugin/variation-price-display/reviews/?filter=5

Your rating keeps us inspired.

Best Regards