WPML
Status
Resolved
Resolved in
4.12.0
Related plugin/theme
WooCommerce Multilingual

Overview of the issue

WPML Multilingual & Multicurrency for WooCommerce users with permalink base slugs that contain slashes ( / ), e.g. shop/product-category, may find those slugs are improperly encoded to something like shop%2Fproduct-category.

This can cause compatibility issues with WooCommerce and its extensions, and users may experience 404 errors on the front-end.

Workaround

As a temporary solution, please try the following steps:


  1. Back up your website completely.

  2. Make sure ALL your plugins are up-to-date.

  3. Edit the file wp-content\plugins\woocommerce-multilingual\inc\class-wcml-url-translation.php and modify Line 947From:
    $location = str_replace( $base_slug, urlencode( $base_slug ), $location );

    To:

    $location = str_replace( $base_slug, implode( '/', array_map( 'urlencode', explode( '/', $base_slug ) ) ), $location );


Please note: this change should not affect slugs that do not contain a slash.

Our development team is working to provide a permanent resolution for this issue.

All known issues →