Please make sure to update to WPML 4.3.5 and check our list of Known Issues before reporting

Hi, Amit here, I am the WPML Support Manager, our current ticket queue is high, update your WPML plugins and make sure you meet the minimal requirements for running WPML before reporting an issue please - many tickets are resolved doing that

Please look at our updated list of Known Issues and you can also use our support search to find helpful information and of course review our documentation before opening a ticket.

If you do need to open a ticket please make sure to provide us with all the needed information as described in this page

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 23 replies, has 2 voices.

Last updated by albaC 2 years, 4 months ago.

Assigned support staff: Shekhar Bhandari.

Author Posts
July 9, 2017 at 8:52 pm #1315260

albaC

I am trying to:

Translate from English to Spanish some strings of the plugin Give (hidden link). I have scanned the plugin to search for strings and I have translated most of them. However, the scanner cannot find the following ones. I have talked to the plugin authors and they told me that I won't be able to find them; so, I have to register this strings manually. All of them are error messages that appaer on the following page when you don't complete the form correctly. Some appear in Safary, others in Firefox...

Site: hidden link

Sentences that I need to register manually:

- Could not find payment information
- Your card number is incorrect
- Donate now
- Your card's expiration year is invalid
- The card number is not a valid credit card number

So, I need you to tell me what I have to do to register them manually. I haven't find any page where you explain step by step (for dumies) how to get it. Most of the pages are for expert people and only explain some of the steps. So, what I need is:

- What is the function that I have to write (step by step).
- Where do I have to paste it, where is the file exactly located.
- Then what else I have to do...

Many thanks!

Best regards,

Alba

July 10, 2017 at 2:01 am #1315310

Shekhar Bhandari
Supporter

Languages: English (English )

Timezone: Asia/Kathmandu (GMT+05:45)

Hello @albac,

Thank you for contacting WPML support. I'd be happy to help you on this.

I have talked to the plugin authors and they told me that I won't be able to find them; 

Could you ask the plugin authors why you will be unable to find them, Isn't the plugin strings localized properly?

I also wanted to know that the sentences that you want to manually register are existing in plugins strings?

Normally to register string manually you can use the following action "wpml_register_single_string" to know more about this please view the following documentation https://wpml.org/wpml-hook/wpml_register_single_string/

Further to help here are the answers to your questions.

#1

- What is the function that I have to write (step by step).

You can use the action I explained above to register the string manually. If you go to that documentation you can see that each parameter is defined there properly and you will get information what you should use there.

#2

- Where do I have to paste it, where is the file exactly located.

This depends upon how your plugin is coded, normally the action should be used where the strings is being written in the .php file. You can search where the strings has been written in the plugin and use the action accordingly.

#3

- Then what else I have to do...

Once you complete the above steps then you can go to string translation and translate those strings.

Let me know if this helps. Look forward to your reply.

Thanks

July 10, 2017 at 5:44 am #1315335

albaC

Dear Shekhar Bhandari,

Thanks for your answer.

The answer of the plugin authors:

1) Those strings are not actually in our code, so it's not currently possible to translate them. We have an open issue with our developers to get that resolved, but in the meantime your only option would be to manually code those translations in yourself.

2) When you scann the plugin, the scanner cannot find strings that I have indicated.

3) Let's try to translate one of the sentences. This one: "Could not find payment information".

This is the code I read on the documentation:

do_action( 'wpml_register_single_string', string $context, string $name, string $value )

So, it should be like this? Is the following code correct?

do_action( 'wpml_register_single_string', 'give', 'payment information', 'Could not find payment information' );

4) How can I know where the strings are located in the plugin? Where do I have to search for them? Once I locate them, where exactly do I have to paste the code?

5) Do I have to add the same code for each sentence that I need to translate, one below the other and separated with ";"? Or I can add all them in the same piece of code?

Many thanks!

Best regards,

Alba

July 10, 2017 at 5:52 am #1315339

Shekhar Bhandari
Supporter

Languages: English (English )

Timezone: Asia/Kathmandu (GMT+05:45)

Hi there,

#3
The code you have presented is OK. 🙂

#4
You should search for the string using file editor and find out which plugin or theme is creating that string.

#5
Once you find that strings you should add the code presented #3 below the strings.

Based on your replies it seems you are trying to search some strings, which you are not sure which plugin is created, so to help you further on this issue, I need to request temporary access (wp-admin and FTP) to your site in order to be of better help. You will find the needed fields for this below the comment area when you log in to leave your next reply. hidden link

This info is private and available to you and supporters only. Read more about this: https://wpml.org/purchase/support-policy/privacy-and-security-when-providing-debug-information-for-support/

Note that:
+ Backup (both files and database) your site before giving us your credentials
+ It would be better if you give me the test site rather than the live site.

We'd like to request the permission to disable, enable and install themes and plugins for this site. Please accept this?

Look forward to your reply.

Thanks

July 11, 2017 at 2:14 am #1316256

Shekhar Bhandari
Supporter

Languages: English (English )

Timezone: Asia/Kathmandu (GMT+05:45)

Hi there,

Could you also provide me the link of the page where these strings are visible?

Look forward to your reply.

Thanks

July 11, 2017 at 5:45 am #1316292

albaC

Hi!

This is the page: hidden link

The messages appear when you don't complete all the requiered fields, or you complete them in a wrong way. Some messages appear depending on the browser. Try Safary, Explorer, Firefox and Chrome.

Many thanks!

Best regards,

Alba

July 11, 2017 at 5:59 am #1316296

Shekhar Bhandari
Supporter

Languages: English (English )

Timezone: Asia/Kathmandu (GMT+05:45)

Hi there,

Thank you for the details.

To debug this issue further, I would need the give plugins, I tried to download those plugins using your ftp but on the provided ftp plugins folder I couldn't find any related plugins of give, so could you please check it once?

Look forward to your reply.

Thanks

July 11, 2017 at 6:03 am #1316297

albaC

You can find them here. There is a WordPress installed in "donaciones" folder.

/web/donaciones/wp-content/plugins

Thanks!

July 11, 2017 at 9:00 am #1316482

Shekhar Bhandari
Supporter

Languages: English (English )

Timezone: Asia/Kathmandu (GMT+05:45)

Hi there,

Upon debugging further I noticed that the plugin is using stripe.js API and the error are received from the remote server, I tried to test this on my localhost but since I don't have stripe test credentials I couldn't test this further, do you have any test credentials so I can test this further.

Look forward to your reply.

Thanks

July 11, 2017 at 9:27 am #1316514

albaC

I am sorry, but the site is already online and there isn't any option to activate the test mode. I have been looking for any alternative, but I couldn't find any.

Could you see the error messages? What can I do to help you?

Many thanks!

Best regards,

Alba

July 11, 2017 at 9:30 am #1316519

albaC

Sorry, just one more detail: You can see all those errors without paying in the live mode. I saw them this way.

Many thanks!

Best regards,

Alba

July 12, 2017 at 6:29 am #1317416

Shekhar Bhandari
Supporter

Languages: English (English )

Timezone: Asia/Kathmandu (GMT+05:45)

Hi there,

I am discussing this issue with our 2nd tier supporters and will respond to you soon.

Thanks

July 12, 2017 at 6:35 am #1317421

albaC

Ok! Thanks! I look forward to hearing from you.

July 12, 2017 at 9:12 am #1317540

Shekhar Bhandari
Supporter

Languages: English (English )

Timezone: Asia/Kathmandu (GMT+05:45)

Hi there,

To debug this issue further, I would need to replicate this issue on my localhost, could you please send me your site snapshot so I can debug this issue further? You can use a plugin like Duplicator and send me the archive and installer file, See more about Duplicator plugin here: http://wordpress.org/plugins/duplicator/

Duplicator instruction
hidden link

Note: Please upload the file in Google drive or Dropbox and share it with me.

Look forward to your reply.

Thanks

July 18, 2017 at 8:11 am #1321600

Shekhar Bhandari
Supporter

Languages: English (English )

Timezone: Asia/Kathmandu (GMT+05:45)

Hi there,

I was waiting for your feedback on this.

Hi there,

To debug this issue further, I would need to replicate this issue on my localhost, could you please send me your site snapshot so I can debug this issue further? You can use a plugin like Duplicator and send me the archive and installer file, See more about Duplicator plugin here: http://wordpress.org/plugins/duplicator/

Duplicator instruction
<em><u>hidden link</u></em>

Note: Please upload the file in Google drive or Dropbox and share it with me.

Look forward to your reply.

Thanks

Also, I request you to follow the below steps and let me know the results.
1) Deactivate WPML
2) Set site default language other than English.
3) Now check if the strings are shown in their languages properly?

Look forward to your reply.