Skip Navigation

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.

No supporters are available to work today on this forum. Feel free to create tickets and we will handle it as soon as we are online. Thank you for your understanding.

This topic contains 26 replies, has 2 voices.

Last updated by Dražen Duvnjak 3 weeks, 6 days ago.

Assigned support staff: Dražen Duvnjak.

Author Posts
March 11, 2021 at 1:50 pm #8285535

Dražen Duvnjak
Supporter

Languages: English (English )

Timezone: Europe/Zagreb (GMT+02:00)

Hello,

okay, great so the main issue is with the invoice not showing translated / correct language when you print them. I was not sure how to check and see the issus, that is why I was asking you to share with me the steps, video was very helpful, thanks.

1) I still see files from the plugin are edited, which is not correct and could cause issues like this or similar problems with the plugin, as already mentioned before.

2) Can you please go to the next clean website and install clean new versions of the plugin, not with your custom edited plugin files.

- hidden link

That way I can see if the issue happens also with a clean fresh version of the plugin and it is a general compatibility bug or issue specific to your website.

Let me know how it goes.

Thanks,
Drazen

March 15, 2021 at 9:30 am #8308849

jetonR

Hello Drazen

The plugin is a premium plugin, so it is connected only for the main website, we will be not able to install it under your dev environment. As for the files i reverted back to their original state. That was the only thing that we touched with the files of that plugin.

Let me know

Thank you

March 15, 2021 at 12:24 pm #8310601

Dražen Duvnjak
Supporter

Languages: English (English )

Timezone: Europe/Zagreb (GMT+02:00)

Hello,

thanks for getting back.

1) You do not need to enter a license or anything, just upload it as a ZIP file and it will work on the sandbox site also.

2) Since you mentioned your removed changes, I download the plugin from your website and installed it on the sandbox site, but I still see changes. Image attached.

3) Can you please download a fresh ZIP file of the plugin WooCommerce Print Invoices/Packing Lists and install it both on your website and sandbox site. If you have troubles you can upload a ZIP file somewhere and share the link with me, and I will do it.

I suspect there are other changes also done to plugin code, you might not be aware of.

Without a fresh copy of the plugin ZIP file, I can not move on to the next step, since we do not support custom-coded plugins, hope you understand.

Kind regards,
Drazen

Screenshot_3.jpg
March 17, 2021 at 11:01 am #8330699

jetonR

Hello Drazen,

Here is a fresh copy of the plugin:
hidden link

If you can install it on both sites our site and your dev environment that will be perfect.

I appreciate your patience and help

Thank you

March 17, 2021 at 1:19 pm #8332723

Dražen Duvnjak
Supporter

Languages: English (English )

Timezone: Europe/Zagreb (GMT+02:00)

Hello,

thanks for sharing the file.

I was finally able to test this issue on the clean sandbox site, and it happens there as well. Even if I translate the string, English (default) language strings are always showing for the printed invoice.

This looks like a compatibility issue with the mentioned plugin, and I have escalated this case to our compatibility team, they will check and advise further.

I will update you as soon as I have some news.

Thanks and kind regards,
Drazen

March 18, 2021 at 8:10 am #8339165

Dražen Duvnjak
Supporter

Languages: English (English )

Timezone: Europe/Zagreb (GMT+02:00)

Hello,

our compatibility team has checked this further and it seems the invoices are printed in the language of the admin user that is printing them. We will take a deeper look to see if there is an easy fix from our side, otherwise, we will contact plugin author to check and advise on this.

In the meantime, I suggest you use this as a workaround, hope it helps.

Please check the video:

- hidden link

I will update you when I have more news.

Kind regards,
Drazen

March 18, 2021 at 10:06 am #8340237

Dražen Duvnjak
Supporter

Languages: English (English )

Timezone: Europe/Zagreb (GMT+02:00)

Hello,

another update, in the meantime our developers found a quick fix. I have just tested it and it works fine.

Can you please also try the next steps and let me know if it works for you?

Workaround:

- add next code to your theme functions.php

add_action ('wc_pip_print', 'wpml_fix_compsupp5568', 10, 3);

function wpml_fix_compsupp5568($type, $order_id, $order_ids) {
	$order_language = get_post_meta($order_id, 'wpml_language', true);
	do_action( 'wpml_switch_language', $order_language );
}

- check now, invoice is printed in order language

Thanks,
Drazen

March 18, 2021 at 1:38 pm #8343163

jetonR

Hello Drazen

Thank you for the quick fix, i included the code under functions.php, now it's showing the invoices properly.

March 18, 2021 at 2:48 pm #8343777

Dražen Duvnjak
Supporter

Languages: English (English )

Timezone: Europe/Zagreb (GMT+02:00)

Hello,

thanks for the feedback.

Great, glad to hear that.

I will update you when I have more news or a version with a permanent fix is released.

Thanks and kind regards,
Drazen

March 18, 2021 at 3:32 pm #8344467

jetonR

Thank you Drazen

I appreciate the help.

March 19, 2021 at 7:24 am #8348955

Dražen Duvnjak
Supporter

Languages: English (English )

Timezone: Europe/Zagreb (GMT+02:00)

[Changing Ticket Status]

April 19, 2021 at 5:38 am #8567629

Dražen Duvnjak
Supporter

Languages: English (English )

Timezone: Europe/Zagreb (GMT+02:00)

Hello,

I just wanted to update your fix from our side will be added in the next versions of WooCommerce Multilingual.

I will be changing this ticket status and update you when the version is out.

Kind regards,
Drazen