如何在最新版本的 Woocommerce 中更改此文本 -
最佳答案
我希望有更好的方法来解决您的问题。只需复制并粘贴您的functions.php 主题。好的
add_filter('woocommerce_catalog_orderby', 'wc_customize_product_sorting');
function wc_customize_product_sorting($sorting_options){
$sorting_options = array(
'menu_order' => __( 'Sorting', 'woocommerce' ),
'popularity' => __( 'Sort by popularity', 'woocommerce' ),
'rating' => __( 'Sort by average rating', 'woocommerce' ),
'date' => __( 'Sort by newness', 'woocommerce' ),
'price' => __( 'Sort by price: low to high', 'woocommerce' ),
'price-desc' => __( 'Sort by price: high to low', 'woocommerce' ),
);
return $sorting_options;
}
关于wordpress - 如何更改 Woocommerce "Sort By"文本?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/37445423/