WPML – Items not being translated since updated version
-
Older version of the plugin is using “woobt_item_id” filter for getting proper product ID when using WPML. Since update to the newest version, it stopped working.
New version (new DB structure) of the plugin is missing this filter and returning wrong product ID leading to show non-translated products in Frequently bought together section on product detail.“woobt_item_id” filter can be seen in wpc-frequently-bought-together.php #2690
$_item_id = apply_filters( ‘woobt_item_id’, absint( $_item_data[0] ?: 0 ) );
and this filter is missing few lines above for 5.0 version
If someone has the same issue, quick fix for me was filter the “woobt_get_items” and add the “woobt_item_id” filter manually outside of the plugin.
add_filter(“woobt_get_items”, function( $items){
array_walk($items, function(&$item){
$item[‘id’] = apply_filters( ‘woobt_item_id’, $item[‘id’] );
});return $items;
}, 10, 4);
Can you check this please or let me know, if we are doing anything wrong? Thanks
- The topic ‘WPML – Items not being translated since updated version’ is closed to new replies.