Home / Forums / WoodMart support forum / Translate Second menu for Product pages
Home › Forums › WoodMart support forum › Translate Second menu for Product pages
Translate Second menu for Product pages
- This topic has 9 replies, 2 voices, and was last updated 2 weeks, 1 day ago by
Aizaz Imtiaz Awan.
-
AuthorPosts
-
November 10, 2025 at 7:19 pm #695228
AntonioS34ParticipantDear staff on my site i link in the private section, if you open it with the default language you can navigate it in the homepage with the default italian menu, and the categories and products pages with second menu for products.
I translated the default menu with polylang pro version and it works but i cannot translate the other menues for products pages.
How to fix it? ThanksNovember 11, 2025 at 1:39 pm #695370
Aizaz Imtiaz AwanKeymasterHello,
Sorry, I did not understand your issue properly. Can you please explain it with the help of a screenshot in which language the header or menu is not translated?
Best Regards.
November 11, 2025 at 1:56 pm #695385
AntonioS34ParticipantDear staff,
I’m using your theme together with Polylang Pro Business + WooCommerce Addon to translate my website into several languages.
I’ve created one header in Italian for the homepage and other pages, and translated it into four languages. I’ve assigned this header through each page’s settings (for example, for the Home and About us pages I used the default header).
For other pages such as Services, Shop, and Product Categories, I created a secondary header (with a different background — the default one is “overlap”, the second is not) and translated it into all languages as well.
The problem is that on single product pages, the header does not inherit the one from the product categories — instead, it automatically loads the default header.
I also tried setting the header directly in Theme Settings → Single Product → Custom Single Product Header, but nothing changes.
If I select the Italian header there and save, switching the language still shows the Italian version — it doesn’t change to the translated header.So how can I manage multiple headers assigned to different pages and product subcategories, while keeping the correct translation for each language?
Thank you in advance for your help.
I also tried adding some code snippets found online to “unlock” the translation of additional headers, but they didn’t work:
// Force Polylang to register header post types so menus work on products
add_action( ‘init’, function() {
if ( function_exists(‘pll_register_post_type’) ) {
pll_register_post_type(‘xts-header’, [‘public’ => true]);
}
});// Make hidden Woodmart CPTs translatable (headers, layouts, etc.)
add_filter(‘pll_get_post_types’, function($types, $is_settings){
// Display them in Polylang settings
$types[‘xts-header’] = ‘xts-header’; // Header Builder
$types[‘woodmart_layout’] = ‘woodmart_layout’; // Layout (if used with conditions)
$types[‘cms_block’] = ‘cms_block’; // HTML Blocks (if used)
return $types;
}, 10, 2);// Ensure they also appear in Polylang settings
add_filter(‘pll_get_post_types’, function($types){
$types[‘xts-header’] = ‘xts_header_builder’;
$types[‘woodmart_layout’] = ‘woodmart_layout’;
$types[‘cms_block’] = ‘cms_block’;
return $types;
});November 11, 2025 at 3:15 pm #695410
Aizaz Imtiaz AwanKeymasterHello,
Please check the single product page now, it is showing the correct header similar to the categories header.
Best Regards.
November 11, 2025 at 3:46 pm #695419
AntonioS34ParticipantNo it doesn’t.
As you can see from the link 1 in the private section, the header showned the menu in the right language but the buttons on the right in the italian language, and also the news link on the top near the flags, and is not correct. And this problem affects all the languages.
It seems that not use the other header (woodmart-> header builder -> these pages has to use the header prodotti IT, header prodotti EN and so on, one header for one language..) hope i explain.November 11, 2025 at 4:04 pm #695424
AntonioS34ParticipantI rewrite:
No it doesn’t.
As you can see from the link 1 in the private section, the header shows the main menu translate in the right language (english) but the buttons on the right are in the italian language because the header translate only the main menu and not the HEADER in totally, and also the news link on the top near the flags, and is not correct. And this problem affects all the languages.
It seems that not use the other headers (woodmart-> header builder -> these pages has to use the header prodotti IT, header prodotti EN and so on, one header for one language..) hope i explain.
While, the other parts of the site has to use the DEFAULT IT, DEFAULT EN and so on…
ALSO there is a bug: i’m using the layouts for the categories and shop page and if i modify these pages with elementor, they lost the conditions and i’ve only to re-edit and re-save them..November 11, 2025 at 7:23 pm #695496
AntonioS34Participanti’m resolving in this way: opening ALL the products and setting the header in the right language. Is not good, by the way. I will not using anymore woodmart translating if this is the result.
November 12, 2025 at 3:36 pm #695660
Aizaz Imtiaz AwanKeymasterHello,
We are sorry that you are experiencing this issue. The code you found is not correct and does not solve this problem.
Also, selecting the desired header for each product is not the proper solution.
In this situation, you need to create separate headers for each language, and in that case, you also need to translate the values in Theme Settings.
However, to investigate in more detail why this is not working on your site, we will need access to your site again (the previous access credentials are no longer valid).
Best Regards,
November 17, 2025 at 11:37 am #696359
AntonioS34Participantaccess created, feel free to “play”, it is the draft version of the site. Thanks
November 18, 2025 at 2:21 pm #696583
Aizaz Imtiaz AwanKeymasterHello,
After reviewing your site, we indeed found the issue that the option in the theme settings “Custom single product header” was not being translated into other languages. We have fixed this on your site and configured it correctly. You can check this on the “TECH SILENCED CEMENT MIXER WITH GEAR REDUCTION TILTING SYSTEM” product. We will also include this fix in our next update.
Best Regards,
-
AuthorPosts
- You must be logged in to create new topics. Login / Register