Skip Navigation

Resolved by author

Topic Tags: Compatibility

Overview of the issue

When using the Product Grid widget from TheGem Theme, you will notice that product attributes cannot be translated.

Workaround

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

  • Open the app/public/wp-content/themes/thegem-elementor/gem-templates/products-extended/content-product-grid-item.php file.
  • Look for line 102.
  • Replace:
    <span class="attribute-name text-body-tiny"><?php echo $attribute_data->name; ?>:</span>
    
  • With:
    <?php 
    	// WPML Workaround for compsupp-7150
    	$attribute_name = apply_filters('wpml_translate_single_string', $attribute_data->name , 'WordPress', 'taxonomy singular name: '.$attribute_data->name );
    ?>
    <span class="attribute-name text-body-tiny"><?php echo $attribute_name; ?>:</span>
    

Leave a Reply

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.

You can use these tags:
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>