Home › Forums › WoodMart support forum › Right filter to change the “You may also like…” Heading in Product page
Right filter to change the “You may also like…” Heading in Product page
- This topic has 7 replies, 2 voices, and was last updated 6 months, 2 weeks ago by
Hung Pham.
-
AuthorPosts
-
February 21, 2025 at 9:39 am #639805
chefneloneParticipantHi there,
I need to change the “You may also like…” Heading in Product page: https://www.pakot.com/en/product/hippie-rainbow-gift-wrapping-paper-roll/
I found this code but not working. Can you tell me the filter name you used in your Theme?
Regards,
Walteradd_filter( 'woocommerce_product_upsells_products_heading', 'bbloomer_translate_may_also_like' ); function bbloomer_translate_may_also_like() { return 'Customers also purchased...'; }
February 22, 2025 at 8:25 am #640072
Hung PhamKeymasterHi chefnelone,
Thanks for reaching to us and appreciate your patience.
+ In order to change / translate words. Please make sure you synced the strings first before changing / translating WooCommerce, WoodMart Core plugins and WoodMart theme. You can refer to article
https://xtemos.com/docs-topic/theme-translation/
https://xtemos.com/docs-topic/how-to-make-woodmart-multilingual-with-wpml/+ You are also need to select the language for the backend and theme settings for admin from the admin user profile, please edit the user’s profile and then select the language for that user it will show the same on the backend.
+ Some strings related to Wishlist / Compare / Login & Register page, you can change in Theme Settings > Shop or Theme Settings > My account https://prnt.sc/W8Tt95stG3YC
Regards,
February 22, 2025 at 2:17 pm #640133
chefneloneParticipantHi there,
I follow all the tips of your answer. But still not working. From my point of view this is not related to “translations” (I use wpml). Problem is the name of the filter ‘woocommerce_product_upsells_products_heading’. It seems to me that your theme uses other name for this filter.
Can you please try this code in your end and let me know if it works for you?
Keep in mind that this code changes the ‘upsells’ products (not the ‘related’ products).add_filter( 'woocommerce_product_upsells_products_heading', 'bbloomer_translate_may_also_like' ); function bbloomer_translate_may_also_like() { return 'Customers also purchased...'; }
Regards,
Walter.-
This reply was modified 6 months, 3 weeks ago by
chefnelone.
-
This reply was modified 6 months, 3 weeks ago by
chefnelone.
February 24, 2025 at 8:32 am #640298
Hung PhamKeymasterHi chefnelone,
First of all, I’m really sorry have taken long time to reply you due to the weekend.
Please remove your code, and I kindly ask that you please provide me temporary wp-admin info (wp-admin URL, username, password) to the Private Content area, this will allow me to thoroughly investigate and address your concerns more efficiently.
Regards,
February 24, 2025 at 1:57 pm #640448
chefneloneParticipantHi there,
I just sent you credentials to my sandbox site.This is the page with the title to change: https://sandbox.latevabotiga.com/en/product/producto-prueba/
I need to change the string “You may also like…”. Capture: https://drive.google.com/file/d/1_6Wc-3y_9HHux6sJPa7b1vQq3Lc8he4h/view?usp=sharingYou can add the snippet here: https://sandbox.latevabotiga.com/wp-admin/admin.php?page=snippets&type=php
Please, let me know.
Walter.-
This reply was modified 6 months, 2 weeks ago by
chefnelone.
February 25, 2025 at 10:19 am #640725
Hung PhamKeymasterHi chefnelone,
Thanks for reaching to us.
Try to use the code below instead of yours. Define the code in the functions.php file in your child theme.
add_filter('woodmart_upsells_products_args', function ( $args ) { $args['element_title'] = 'Customers also purchased...'; return $args; } );
Regards,
February 25, 2025 at 3:12 pm #640870
chefneloneParticipantThank you very much.
February 26, 2025 at 11:54 am #641057
Hung PhamKeymasterHi chefnelone,
Glad to hear your issue has been resolved. Keep us in mind for future questions and concerns, we’re always here to help!
If you have a quick minute we always appreciate a 5-star rating on our theme!
https://themeforest.net/item/woodmart-woocommerce-wordpress-theme/reviews/20264492
Your feedback is the motivation to improve our work and services.
Regards,
-
This reply was modified 6 months, 3 weeks ago by
-
AuthorPosts
- You must be logged in to create new topics. Login / Register