-
AuthorPosts
-
April 1, 2015 at 8:29 pm #240375
christine-i
ParticipantHello,
I´ve got the following problem:
I have installed the WooCommerce Plugin and the WooCommerce German Plugin. If I use a standard WordPress Theme everything works fine and every button of the shop is in german. But if I activate the X theme suddenly some of the buttons are in english. Not all buttons are affected, but only some. What can I do so that all buttons are german?Thanks in advance.
April 1, 2015 at 10:08 pm #240443Rue Nel
ModeratorHi There,
Thanks for posting in!
Woocommerce has a bundled German translation. If you use German language in your install, woocommerce will automatically display German if you are using the default WordPress template. The default WordPress templates doesn’t have any woocommerce template bundled in it. Having said that, X theme has bundled woocommerce template and you still need to translate X theme to German. That is why you are seeing some of the contents is in English.
You can find the default.po language file for your translation needs in
/wp-content/themes/x/framework/lang/
. To start with your translation, download this file and rename it to de_DE.po. Using Poedit, you can translate each of the keyword found in X theme. If you want easier management for your translation, you can use a 3rd party translation plugin, WMPL.Please refer to our Translation in our knowledge base.
Please let us know how your translation goes.
April 7, 2015 at 9:03 am #243876christine-i
ParticipantThis reply has been marked as private.April 7, 2015 at 11:47 am #244000Zeshan
MemberHi Christine,
thanks for writing in!
The fact that languages uses textdomain like namespaces, translation will only work on current textdomain which is __x__. Every theme or plugin, have their own text domain.
With woocommerce plugin, the translation uses woocommerce textdomain, eg.
__('My String', 'woocommerce')
as plugin, but for X’s woocomerce templates, it uses theme textdomain ( __x__ ).What you could do is setup a child theme, and copy woocommerce templates (eg. /x/woocommerce/ ) then replace all occurrences of __x__ by woocommerce. And see if it works because the loaded woocommerce’s textdomain is for the plugin.
Thanks!
April 11, 2015 at 3:32 pm #247116christine-i
ParticipantThanks a lot. This works great. The cart and checkout-page is translated now.
But there is still one problem:
I can´t find the file of the review-page of Woocommerce. It´s the page where costumers can rate the product and leave a comment.
Could you please tell me where I can find it?April 11, 2015 at 5:55 pm #247164christine-i
ParticipantNow I have solved this problem. It´s directly in the “woocommerce”-folder.
Thanks.April 11, 2015 at 10:28 pm #247275Rad
ModeratorGood to hear that and good job! 😉 Thanks!
October 2, 2015 at 5:00 am #607881tpham76
ParticipantDear christine-i,
I have the same problem. Is it possible to get the translated files from you?
Many thanks in advanced!
TrucOctober 2, 2015 at 6:05 am #607943Jack
KeymasterHi there Truc,
Since WooCommerce 2.2, it should automatically pull in a translation (if available) based on your sites language. 🙂
https://docs.woothemes.com/document/woocommerce-localization/
It pulls in the translation from https://www.transifex.com/woothemes/woocommerce/ I just tested it by changing my language to Deutsch in wp-admin > settings > general.
Thank you!
December 14, 2015 at 4:22 am #705715quinex
ParticipantHi Staff
Not completely correct.
I have set the site to Dutch language but for woocommerce there are still english translations
Single product page:
– reviews is completely in english
– related products (this title is english)Shopping cart:
– all is in english except for the checkout button and shipping rule
Checkout page:
– the billing address and shipping address titles are in english
So i guess we still would need to copy the language file to child theme folder, rename it and translate ?
Or do we need the woocommerce files for this?
😉
Cheers | Have a great day
December 14, 2015 at 5:01 am #705747Zeshan
MemberHi there,
Thanks for writing in!
You need to translate those strings in X language file x.pot located in folder /wp-content/themes/x/framework/lang/. For more detail, please review our KB article on Translation. You can use Poedit to translate X language file.
Thank you!
December 14, 2015 at 6:21 am #705855quinex
ParticipantHi
I copied x.pot to child_theme/framework/lang/
translated everything for woocommerce, but in front nothing is visible…
so i must be doing something not quite correct 😉
Thanks
December 14, 2015 at 6:41 am #705886Christopher
ModeratorHi there,
Please create a “languages” folder in your child theme, for example /wp-content/themes/x-child/languages and upload your translations to that file.
Add following lines in child theme’s functions.php :
add_action( 'after_setup_theme', 'load_child_language' ); function load_child_language() { load_child_theme_textdomain( '__x__', get_stylesheet_directory() . '/languages' ); }
Hope it helps.
December 14, 2015 at 6:45 am #705889quinex
ParticipantPfffrlll… i was taking the shortcut by not reading the translations section in KB and just adding the translations… my bad…
I’ll go through it and follow the rules 😉
Thanks
December 14, 2015 at 7:11 am #705936Christopher
ModeratorYou’re welcome.
-
AuthorPosts
- <script> jQuery(function($){ $("#no-reply-240375 .bbp-template-notice, .bbp-no-topic .bbp-template-notice").removeClass('bbp-template-notice'); }); </script>