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 thread is resolved. Here is a description of the problem and solution.

Problem:
The user wants to display different Bank Account Numbers for each language (the data is set under WooCommerce > Settings > Checkout > BACS > Account Details )

Solution:
- Add the following XML code to WPML > settings > Custom XML Configuration

<wpml-config>
<admin-texts>
<key name="woocommerce_bacs_accounts">
    <key name="0">
        <key name="account_name" />
        <key name="account_number" />
        <key name="bank_name" />
        <key name="sort_code" />
        <key name="iban" />
        <key name="bic" />
    </key>
    <key name="1">
        <key name="account_name" />
        <key name="account_number" />
        <key name="bank_name" />
        <key name="sort_code" />
        <key name="iban" />
        <key name="bic" />
    </key>
</key>
</admin-texts>
</wpml-config>

- Translate it using String Translator
-

This topic contains 4 replies, has 2 voices.

Last updated by przemyslawD-3 6 months, 1 week ago.

Assigned support staff: Diego Pereira.

Author Posts
April 15, 2019 at 10:36 am #3612475

przemyslawD-3

How can I choose different account number for each currency? I create two account in Bank Transfer Options (attachment) but at the and the customer sees both numbers (attachment). How should I change this?

I found this solution:
https://wpml.org/forums/topic/how-to-show-different-bank-account-details-for-each-language-during-check-out/

but I'm afraid that any code change in wp-content/plugins/woocommerce-multilingual/wpml-config.xml will disappear after first WPML update. And it was added 5 years ago.

Maybe is there some plugin that help solve this in simply way?

April 15, 2019 at 8:00 pm #3616265

Diego Pereira
Supporter

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

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

Hello @przemyslawd-3, welcome to the WPML support Forum!

Please try the solution provided on the reference ticket (https://wpml.org/forums/topic/how-to-show-different-bank-account-details-for-each-language-during-check-out/), but instead of adding it to "wp-content/plugins/woocommerce-multilingual/wpml-config.xml", please add it to WPML > Settings > Custom XML Configuration. This way it will be not removed on the next update.

After that, please translate thorugh WPML > String Translator.

Please let me know if it worked for you.

All the best,
Diego

April 16, 2019 at 7:28 am #3618911

przemyslawD-3

I can't save Custom XML 🙁 XML is not valid:

"Element 'key': No matching global declaration available for the validation root."

April 16, 2019 at 6:48 pm #3624851

Diego Pereira
Supporter

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

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

Hi there,

Please try with the following code:

<wpml-config>
<admin-texts>
<key name="woocommerce_bacs_accounts">
    <key name="0">
        <key name="account_name" />
        <key name="account_number" />
        <key name="bank_name" />
        <key name="sort_code" />
        <key name="iban" />
        <key name="bic" />
    </key>
    <key name="1">
        <key name="account_name" />
        <key name="account_number" />
        <key name="bank_name" />
        <key name="sort_code" />
        <key name="iban" />
        <key name="bic" />
    </key>
</key>
</admin-texts>
</wpml-config>

Please let me know if it worked for you.

Kind regards,
Diego

April 17, 2019 at 10:50 am #3629819

przemyslawD-3

Yes, it works. Thank You for Your help 🙂