【问题标题】:WooCommerce: Sorting problem: Selected orderby value overwrites filter valueWooCommerce:排序问题:选择的 orderby 值覆盖过滤器值
【发布时间】:2021-05-01 02:39:07
【问题描述】:

我的 woocommerce 商店出现分类问题。我在我的商店里卖鞋,我有一些过滤器可以显示用户喜欢的鞋,例如:shoe typebrandsize , 颜色

即使我将它们全部组合起来,它们都可以很好地与 orderby 下拉选择一起使用。 But when a size is selected and for example "order by price" the filter value of size is overwritten by the selected orderby value

选定的过滤器尺寸 10

../shop/?filter_size=10

选择过滤器size 10orderby price

../shop/?orderby=price&filter_size=price

编辑:

如果我先选择 orderby price 然后选择 size 10 就没有问题:

shop/?filter_size=10&orderby=price

我使用:WooCommerce 标准 小部件过滤器:“产品按属性”

这个错误可能来自哪里?

【问题讨论】:

    标签: php wordpress sorting woocommerce sql-order-by


    【解决方案1】:

    问题解决了。我的子主题 woocommerce 文件夹中有一个 orderby.php 的副本,导致此错误。删除后一切正常。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2020-08-21
      • 2014-10-18
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2023-03-22
      相关资源
      最近更新 更多