Skip Navigation

[Resolved] Conflict with WPBakery on Category Archives

This support ticket is created 4 years, 1 month 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.

No supporters are available to work today on Toolset forum. Feel free to create tickets and we will handle it as soon as we are online. Thank you for your understanding.

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/Hong_Kong (GMT+08:00)

This topic contains 3 replies, has 2 voices.

Last updated by Luo Yang 4 years ago.

Assisted by: Luo Yang.

Author
Posts
#1564599

Please note: as part of debugging, I have disabled all plugins except for WPBakery and Toolset Types; additionally, I have commented out the entirety of my functions.php, and stripped my template page to have no additional code or scripts beyond standard WordPress header and footer. Disabling Toolset Types immediately fixes the issue. I am opening an identical ticket with WPBakery as well.

On Friday, 3/27, from 10:30a EST to 12:30pm EST, I will need to restore standard functionality for an internal review. If you happen to access this ticket in that period, please trust that I have already eliminated all other sources of interference before opening this ticket.

I am trying to: ===========================================================

I have a custom post type, "Products", which uses standard Categories. It uses all default settings (plus featured image).

On each category archive, I would like to use a [vc_basic_grid] to show Products in that Category with some filtering options.

On a standard page, when I use [vc_basic_grid], all products load as expected.

When this shortcode is executed on a DIFFERENT category archive page than the category it is set to display, all products load as expected.

When this shortcode is executed on the SAME category archive page as what is being shown, one product will always be missing; it will either be the top or bottom product of the wordpress post order stack ( NOT the query stack! the same product will be missing regardless of sort_by or sort_order settings in the [vc_basic_grid] shortcode! Using post ordering plugins will shift which product is missing but since I have now disabled these I am not confident whether it is the first or last in the stack).

Here is the contents of my category.php file which you can use for testing in an environment with WPBakery turned on:

<?php get_header(); ?>
<section id="content" role="main">	
<?php echo do_shortcode('[vc_basic_grid post_type="product" max_items="-1" element_width="3" item="381" taxonomies="20" offset="0"]'); ?>
</section>
<?php get_footer(); ?>

In this case, Taxonomy 20 is the category "Gifts". You would need to set this to some category's ID on your environment. You will note that I have stripped the parameters down to their bare essentials, and that nothing here is dynamic - I am asking every category archive to load a grid showing products in the Gifts category.

Link to a page where the issue can be seen: ===========================================================

hidden link
hidden link

I expected to see: ===========================================================

Both pages should show both of the products in category "Gifts".

Instead, I got: ===========================================================

The category archive of frappes does not conflict and both load;
The category archive of Gifts does conflict, and one of the products does not load.

#1565063

Hello,

Since it is a copatibility issue with WPBakery plugin, but I do not have a copy of WPBakery plugin(version 6.1) in my localhost.

Please provide a full copy of your website in below private message box, I need to test and debug it in my localhost, thanks.
https://toolset.com/faq/provide-supporters-copy-site/

You can put the duplicator package in your own google drive disk, and share the link.

#1567561

Thanks for the details, I am downloading the files, will update here if there is anything found

#1567919

Here are what I found, I can see the problem with your duplicator package, and I have tried these:
1) Deactivate Toolset Types plugin, activate WPBakery plugin only.
2) Switch to WordPress default theme 2020
3) Create two new posts, assign with same category "cat1", for example:
- Post 1, with category "cat1" (term's ID is 30)
- Post 2, with category "cat1"
Edit theme file "index.php", add below line:

<?php echo do_shortcode('[vc_basic_grid post_type="post" max_items="2" element_width="3" item="381" taxonomies="30" offset="0"]'); ?>

I get the same result, it outputs only one item in archive page of "cat1".

So it should be a problem of WPBakery plugin, Can you confirm it in your website?

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