Multilingual sites
Kudos Donations works with WPML and Polylang. One campaign serves every language of your site, so all donations count towards the same total and goal, whichever language the donor used.
Translating campaigns requires Kudos Donations 4.4.0 or later. With WPML you also need its String Translation add-on.
How it works
When you save a campaign, Kudos Donations registers its text with WPML or Polylang for translation. Campaigns that existed before you installed WPML or Polylang are registered automatically, so there is no need to save each one again.
The following campaign text can be translated:
- The title and text of each section of the donation form (see Text)
- The return message title and text
- The terms and conditions link and the privacy policy link
- The custom return URL
On a translated page, the donation form shows the campaign's text in that page's language. Text that hasn't been translated yet shows in the original language. The campaign edit screen always shows the original text, so you can keep editing your campaign as usual.
Translating campaign text
WPML
Go to WPML → String Translation and choose the domain kudos-donations-campaign-ID, where ID is the campaign's ID, shown next to its name under Donations → Campaigns. Translate each string into your other languages.
Polylang
Go to Languages → Translations and choose the group kudos-donations-campaign-ID, where ID is the campaign's ID, shown next to its name under Donations → Campaigns. Enter a translation for each string and save.
Polylang translates by the text itself, so the same text in different campaigns shares one translation. For example, translating Support us! once translates it in every campaign that uses it.
Placing the form on translated pages
Use the same campaign on every translation of a page: choose the same campaign in the block, or keep the same campaign_id in the shortcode. Don't create a separate campaign for each language, or the donations and goal will be split between them.
Button label
If you leave the button label empty, the button shows Donate now in the language of the page. This uses Kudos Donations' own translations from translate.wordpress.org, so it works for every language that Kudos Donations has been translated into.
If you enter your own label, translate it like the rest of the page:
- WPML: the label appears as text to translate in WPML's translation editor, together with the rest of the page.
- Polylang: each language has its own copy of the page. Edit the translated page and change the label in its block or shortcode.
Emails and receipts
Receipt emails and PDF receipts are sent in the language of the page the donor used to donate. This applies to every site, not only multilingual ones, as long as Kudos Donations has been translated into that language.