• Resolved titsmaker

    (@titsmaker)


    Let’s say we have a site example.com with with such product attributes as “flavour” and “size”. Then, if we want to get products which have banana flavour and big size at the same time we use such a link:
    example.com/?pa_flavour=banana&pa_size=big
    Breadcrumbs would be:
    Home / Product Flavour banana
    No word about big size.
    Looks like you’re always getting alphabetically first attribute.
    When you use product attribute + tag query you’re always getting breadcrumbs for tag archive page without mention of attribute used for query.
    Also breadcrumbs for tag archive for some reason has “shop” in the path while attribute archive page does not.
    E.g. for
    example.com/?pa_flavour=strawberry&tag=glowing
    we will get such breadcrumbs:
    Home > Shop > Products tagged "glowing"
    All these leads to confusing user experience and poor navigation.
    I studied a code a little bit and my assumption is that it’s related to using get_queried_object() in class-wc-breadcrumb.php which retrieves only one taxonomy for query.
    The issue is described here – https://core.trac.www.ads-software.com/ticket/5358 and here – https://core.trac.www.ads-software.com/ticket/31680
    The solution in my opinion is to retrieve all taxonomy from query and let user set hierarchy in which it’s shown in breadcrumbs.

Viewing 4 replies - 1 through 4 (of 4 total)
  • Thread Starter titsmaker

    (@titsmaker)

    ??

    Plugin Support con

    (@conschneider)

    Engineer

    Hi there,

    > The solution in my opinion is to retrieve all taxonomy from query and let user set hierarchy in which it’s shown in breadcrumbs.

    I concur.
    However this sounds like an enhancement request / PR for WordPress core. Maybe another core method / helper can do this for you(?)

    The tickets you mention also one reply where someone says that: get_query_var('tag') does the trick for them.

    Kind regards,

    Plugin Support con

    (@conschneider)

    Engineer

    Hi there,

    We haven’t heard back from you in a while, so I’m going to mark this as resolved – if you have any further questions, you can start a new thread.

    Kind regards,

    Thread Starter titsmaker

    (@titsmaker)

    I have no idea why this “sounds like an enhancement request / PR for WordPress core” if breadcrumbs are managed by WooCommerce.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Confusing breadcrumbs for multiple queries’ is closed to new replies.