WPML
Status
Resolved
Resolved in
4.7.2

Overview of the issue

When you use WooCommerce’s products shortcode and include the category attribute like so:

[ products category="product_category_slug" ], the translated page will not show up the products assigned to that product category.

Workaround

A temporary workaround should be to:
Go to wp-content/plugins/woocommerce-multilingual/classes/shortcodes/class-wcml-wc-shortcode-product-category.php line 43 and find ->map( function ( $category ) { return get_term( $category, 'product_cat' ); } );
Replace it with ->map( function ( $slugOrId ) {
if ( is_numeric( $slugOrId ) ) {
return get_term( $slugOrId, 'product_cat' );
}
return get_term_by( 'slug', $slugOrId, 'product_cat' );
} );

All known issues →