Using loop builder on Single Product Template

edited February 2023 in Theme Options

Hello,

I saw this new functionality of Loop builder and found it very similar to like Related Products of Woocommerce. But the loop builder is more powerful in my opinion.

So I want to achieve the following:

I have created a template for Single Products. In that page I want to add 2 loop builders.

1) One loop builder where I show 4 (random) images/products of the same category of the current product.

2) One loop builder of another category (choose randomly), same with 4 (random) images.


The problem here is that I only can select 'All categories' or a specific category.

Is this possible?


Also another question: the dots for navigation (in loop builder) have now a blue color on my site. But is it possible to change that?

Comments

  • Hi,

    At the moment, there is no option to navigate in the same category, unfortunately.

    However, your idea is very good, and I passed it on to the dev team, and we will add it to our to-do list.

    For now, to achieve that, you would have to create a product template for each category, and select this category in the query loop.


    Dots color you can change in the Style tab of the query loop under the pagination tab.

    Best regards

  • Yes, I was also thinking about creating a template for each category, but it is too much work and repetitive. That's why I wanted to know if what I asked was possible.

    But good to see that you added it to your to-do list!

    For the pagination, it worked!


    I also have another question:

    In Woocommerce you have Related products. When adding a tag in the product page (admin dashboard) there will be a css class created. So if I add a tag "landscape" there will be a css class added like "product_tag-landscape". In the loop builder I don't see this. Am I missing something here or is this not available?


    I added the tags in order to use custom css class for certain products.

    So if I add 2 tags, like Portrait and Landscape, I want to show products with tag 'portrait' in portrait mode and products with tag 'landscape' in landscape mode.

  • Tags are not available in the loop builder.

    We will consider adding this as well. ?


    Best regards

  • edited February 2023

    Ok, so I still have a problem then.

    I wanted to create a "Related products" with this option. However, without the latter option I cannot achieve this.

    For now I need to use the default "related products" of woocommerce. BUT I don't like the design of this. Is there any css code to change this to the exact same as query loop builder?

    The problems I have with the default woocommerce related products, is that is not a slider.

    It just shows my products beneath each other (2 columns). With the query loop it is shown as 1 colum and can swipe left/right, etc.

    Is there any other solution to this problem I have?

    So I actually need a Woocommerce related products slider.

    I tried to install the following plugin: https://wordpress.org/plugins/wt-woocommerce-related-products/

    But somehow it does not work. I think it is not compatible with BeTheme. The following is as stated in their docs. I should enable this to override default related products functinality, but it is not working


    EDIT: with 'default' related products I mean this:


  • I can see that this plugin offers a shortcode to display related products.

    Please, try to put it on the product template in the Column text element.

    Best regards

  • Yes, but what should the product id be? I want it dynamically, because I use this in a template.

    Or should it be just xx ?

  • We did not test this plugin, so it would be best if you contact the plugin author regarding this, but before you can try without this parameter, and remove the whole "product_id='xx' ".


    Best regards

Sign In or Register to comment.