This is the technical support forum for WPML - the multilingual WordPress plugin.

Everyone can read, but only WPML clients can post here. WPML team is replying on the forum 6 days per week, 22 hours per day.

This topic contains 7 replies, has 2 voices.

Last updated by silkeK-4 2 months ago.

Assigned support staff: Diego Pereira.

Author Posts
August 15, 2019 at 11:22 am #4400421

silkeK-4

i cannot find a way to have the order date, shown at the end of checkout process, translated into second language. it's always shown in first language's format/month name.

i already searched all strings, but cannot find anything, neither a setting.

can you please tell me how to do this?

thank you

August 15, 2019 at 2:19 pm #4401527

Diego Pereira
Supporter

Languages: English (English ) Spanish (Español ) Portuguese (Brazil) (Português )

Timezone: America/Sao_Paulo (GMT-03:00)

Hello @silkek-4, welcome to the WPML support Forum!

Could you please send us a screenshot of the string? As it have a date, it may have variables on it. We need to check the structure.

Usually, these are the steps to translate a string from the theme or a plugin:
- Make sure you have the Translation Magagement and String Translator extensions active. If not, you can download here: https://wpml.org/account/downloads/
- Go to WPML → Theme and Plugin Localization → Strings in the themes (or Strings in the plugins)
- Select your theme and click on Scan selected theme for strings
- Go to WPML → String Translation and search for the Strings
- Translate the string, check the Translation is complete field and click on Save.

Ref: https://wpml.org/documentation/getting-started-guide/string-translation/

If you can not find the strings, check it is possible to find it on the Translate texts in admin screen page, like on this link: https://wpml.org/documentation/getting-started-guide/string-translation/#admin_texts

Please let me know if it worked for you.

All the best,
Diego

August 15, 2019 at 2:47 pm #4401803

silkeK-4

this i a screenshot of page after having placed an order.
as you can see, date is in german format, with german month name, though all the rest is correctly translated.

it's the same in confirmation email sent to client.

i had already searched for the months' names in strings, but they are not there.

August 15, 2019 at 7:04 pm #4403135

Diego Pereira
Supporter

Languages: English (English ) Spanish (Español ) Portuguese (Brazil) (Português )

Timezone: America/Sao_Paulo (GMT-03:00)

Hi there,

I need to check how the date is set in the code. Is this string generated by woocommerce itself or some other plugin?

Kind regards,
Diego

August 15, 2019 at 7:54 pm #4403225

silkeK-4

... i found it in woocommerce template thankyou.php

<?php _e( 'Date:', 'woocommerce' ); ?>
<?php echo wc_format_datetime( $order->get_date_created() ); ?>

so it's from woocommerce itself.

August 16, 2019 at 6:48 pm #4407879

Diego Pereira
Supporter

Languages: English (English ) Spanish (Español ) Portuguese (Brazil) (Português )

Timezone: America/Sao_Paulo (GMT-03:00)

Hi there,

Thanks for the feedback. From what I see, this function follow the format defined on "Settings > General > Date Format" (see screenshot). Could you please try this tutorial and check if it works for you? https://wpml.org/documentation/getting-started-guide/translating-your-sites-date-format-using-wpml/

I also checked your debug log and it seems that the WPML needs update. Could you please update the plugins to the lastest version?

Please let me know if it works for you.

Kind regards,
Diego

August 19, 2019 at 10:33 am #4415231

silkeK-4

yes, this worked! thank you very much!

August 19, 2019 at 10:33 am #4415237

silkeK-4

My issue is resolved now. Thank you!