Sauter la navigation

Open

Topic Tags: Compatibility

Overview of the issue

If you are using WoodMart theme in conjunction with WPML, you may experience that the Compare Feature does not function as expected. After adding products to the compare list, attempting to remove a product from the list fails, with the product persisting despite user actions.

Workaround

Please, make sure of having a full backup of your site before proceeding.

  • Open …/wp-content/themes/woodmart/inc/integrations/woocommerce/modules/compare/class-compare.php file.
  • Replace:
    				if ( $id === $product_id ) {
    					unset( $products[ $key ] );
    				}
    
  • With:
    				if ( $id == $product_id ) {
    					unset( $products[ $key ] );
    				}
    

Laisser une réponse

Please stay on topic and be respectful to others. If you need help with issues not related to this post, use our Support Forum to start a chat or submit a ticket.

Vous pouvez utiliser ces balises :
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>