Home Forums Basel support forum Swatches bug?

Swatches bug?

Viewing 13 posts - 1 through 13 (of 13 total)
  • Author
    Posts
  • #767

    me
    Participant

    Hi,

    Scenario:

    Swatches_
    Woocommerce – Attributes – Name: Color
    Attributes – Color include: White, Gray, Silver

    Products_
    Product Data (Variable Product) – Name: Poster
    Attributes – Select Color, value all – White, Gray, Silver
    Checkbox – Visible on the product page, Used for variations
    Variation – Any Color

    Theme settings_
    Shop – Attribute swatches – pa_color

    Result:
    – Or Display last swatch color – Siver
    – Or Don’t display swatches on shop page

    PHP-Notice
    Trying to get property of non-object 2 wp-content/themes/basel/inc/classes/Swatches.php:
    line – 91, 92, 93


    If on tab Variation – disable Any Color, and add all colors: White, Gray, Silver, then swatches will display on shop page.

    #769

    Artem Temos
    Keymaster

    Hello,

    Thank you for your message.

    Please provide us your web-site link and admin access so we could take a closer look to your problem. When we try to reproduce it on our development site we don’t see this.

    Kind Regards,
    Xtemos

    #779

    me
    Participant

    Ok, test site ready.

    #781

    Artem Temos
    Keymaster

    Please check login details, we can’t login.

    #782

    Artem Temos
    Keymaster

    And swatches on the shop page may be shown only if you add each attribute term as an separate variation. So attribute that you choose in Theme Settings -> Shop -> Attribute Swatches have to be presented in product variations to display them on the shop grid.

    Regards
    Xtemos

    #783

    me
    Participant

    Ok, i regenerated data without special symbols.

    #785

    Artem Temos
    Keymaster

    Okay thanks. Please check your product now. So it is required to add each term as a separate variation to show them on the shop page.

    #786

    me
    Participant

    I realized that its only works if there is separate variations )) It’s necessary to add in the FAQ, what doesnt work with variation – any [variation].

    #787

    Artem Temos
    Keymaster

    Okay, will try to explain in more details in our theme documentation.

    Don’t worry about PHP notices, they are absolutely harmless, and we will fix them in the next update.

    About special symbol in the product name, could you try to use ‘x’ character instead of special char? It will solve the problem. Other way you need to edit our js/functions.js file and remove the following line from there .replace(/&/g, '&'). To see the changes you need to disable including minified JS in Theme Settings -> Performance.

    #789

    me
    Participant

    About special symbol in the product name, could you try to use ‘x’ character instead of special char?

    Default WordPress converts symbol x between numbers to special symbol × =)

    Converting x to × in wp_texturize() converts too much. Strings like 4×4

    Resolve – comment from line 278 in /wp-includes/formatting.php

    // 9×9 (times), but never 0x9999

    #790

    Artem Temos
    Keymaster

    So you have solved this? 🙂

    #794

    me
    Participant

    Yes, commenting in the file /wp-includes/formatting.php =) another solution i haven’t found so far.

    #796

    Artem Temos
    Keymaster

    Okay, great 🙂

Viewing 13 posts - 1 through 13 (of 13 total)

The topic ‘Swatches bug?’ is closed to new replies.