Skip Navigation

[Resolved] The "Sale" badge disappears from the "Shop" archive page if "toolset" is activat

This support ticket is created 2 years, 3 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Karachi (GMT+05:00)

This topic contains 7 replies, has 2 voices.

Last updated by esztanygaleria-srlE 2 years, 3 months ago.

Assisted by: Waqar.

Author
Posts
#2254093

Hello,

The "Sale" badge disappears from the "Shop" archive page if "toolset" is activated. On the homepage where I've used Kadence blocks to display the latest products the "Sale" badge it appears (hidden link) but on the default archive page it doesn't (hidden link)

Could you have a look and let me know what is wrong? I can set up a staging area for you to test it.

Thank you,
Robert

#2254541

Waqar
Supporter

Languages: English (English )

Timezone: Asia/Karachi (GMT+05:00)

Hi Robert,

Thank you for contacting us and I'd be happy to assist.

To troubleshoot this, I'll need to see how these two pages are set up in the admin area and it would help if you could share temporary admin login details for the staging website.

Note: Your next reply will be private and it is recommended to make a complete backup copy, before sharing the access details.

regards,
Waqar

#2255883

Waqar
Supporter

Languages: English (English )

Timezone: Asia/Karachi (GMT+05:00)

Thank you for sharing these details, but your CDN service (Cloudflare) is blocking access to the website's admin area.

Can you please share a clone/snapshot of the website, so that I can investigate this on my test server?
( ref: https://toolset.com/faq/provide-supporters-copy-site/ )

I've set your next reply as private again.

#2256241

I have deactivated Cloudflare. Please have a look again.

Thank you,
Robert

#2257471

Waqar
Supporter

Languages: English (English )

Timezone: Asia/Karachi (GMT+05:00)

I was able to access the website's admin area, thank you.

During troubleshooting, I noticed that the website is not using any Toolset WordPress Archive for WooCommerce shop or product category archive pages, which means that the layout and styles of these archive pages are being controlled by the active theme.

In this case, you don't need to activate the "Toolset WooCommerce Blocks" plugin. Please deactivate this plugin and the "sale" badge will start showing correctly.

#2257541

Hello Waqar,

Indeed I'm not using the "Toolset WooCommerce Blocks" plugin for the archive page but I'm using for the product pages, so I can't deactivate it.

Could you help me with any other solution? Maybe is there a solution under Toolset > Settings > Front-end Content

Thank you,
Robert

#2258887

Waqar
Supporter

Languages: English (English )

Timezone: Asia/Karachi (GMT+05:00)

Thanks for writing back.

During testing on my website, I was able to fix the compatibility with sales badge styles, using some custom code:


function custom_sale_badge_fix() {
ob_start(); ?>
<script>
( function( $ ) {
    $( document ).ready( function(){
        $('.products.product-archive > .entry .wcviews_onsale_wrap').removeClass('wcviews_onsale_wrap');
    } );
})( jQuery );
</script>
<?php echo ob_get_clean();
}
add_action( 'wp_footer', 'custom_sale_badge_fix' );

The above code snippet can be included through either Toolset's custom code feature ( ref: https://toolset.com/documentation/adding-custom-code/using-toolset-to-add-custom-code/ ) or through the active theme's "functions.php" file.

I hope this helps and please let me know how it goes.

#2258951

Thank you for your help!

This ticket is now closed. If you're a WPML client and need related help, please open a new support ticket.