Localize text

You can localize or customize strings in the SDK UIs.

Before you start

Before you start, the following information is useful to know:

  • The Support SDK comes localized into 33 languages out of the box. They are listed in Supported languages below. The list of strings that you can customize is listed in List of Strings below.
  • If you have enabled logging, you will see the keys of localized strings in the debug area in XCode when you are using the SDK.

Note: If you change the locale programmatically during the runtime of the application, the change won't be applied to the UI element. You must restart the application to update the locale.

Customize existing strings

If the Support SDK already includes localized strings for the language you are interested in, you can override the strings if required.

If your project does not yet have a Localizable.strings file with the different language variants, create it now. To do that:

  1. In Xcode, select File > New > File, then select Resource in the iOS category in the sidebar.

  2. Select Strings File from the files and click Next.

  3. Name the file Localizable and click Create.

To then customize the Support SDK strings with new values:

  1. Choose the strings to customize and add them to the Localizable.strings file as follows:

    // add a key and change the value to what you want"ios.ZDKHelpCenter.support.title" = "Your Custom String Value";
  2. Make sure that the file is in the Copy Bundle Resources section of the Build Phases tab in Xcode.

Add a new localisation

If the Support SDK does not include localized strings for the language you are interested in, you can add new ones.

Select your Localizable.strings file, and in the right pane click Localize. When you select the missing language a new variant of Localizable.strings will be created for it.

In the new file, add translations for all of the strings in the Support SDK's Strings.bundle.

Use a different strings file

If you would like to use a different strings file to the one provided with the Support SDK, you can easily change it.

Localizable.strings is the standard name for strings files. If you need to use a strings file named some-other-name.strings, add the file to your project and register some-other-name as follows.

Swift

ZDKLocalization.registerTableName("some-other-table-name")

Objective-C

[ZDKLocalization registerTableName:@"some-other-table-name"];

List of strings

"ios.ZDKHelpCenter.articleAttachmentsError" = "Failed to fetch attachments";"ios.ZDKHelpCenter.helpCenterOverview.see_all.singletitle" = "See 1 article";"ios.ZDKHelpCenter.helpCenterOverview.see_all.title" = "See all %lu articles";"ios.ZDKHelpCenter.helpCenterOverview.title" = "Help";"ios.ZDKHelpCenter.noArticles.title" = "No articles found";"ios.ZDKHelpCenter.search.noResults.title" = "No results for";"ios.ZDKHelpCenter.support.contactError" = "Unable to connect";"ios.ZDKHelpCenter.support.contactSupport" = "Contact us";"ios.ZDKHelpCenter.toastRetryButton" = "Retry";"ios.ZDKRequests.commentList.error" = "Failed to load comments";"ios.ZDKRequests.connectionError" = "No connection";"ios.ZDKRequests.conversations.back.button" = "Back";"ios.ZDKRequests.createRequest.attachments.confirm" = "OK";"ios.ZDKRequests.createRequest.attachments.download" = "Downloading";"ios.ZDKRequests.createRequest.attachments.downloading" = "File attachment is still downloading. Please wait.";"ios.ZDKRequests.createRequest.cancel.button" = "Cancel";"ios.ZDKRequests.createRequest.cellError" = "Message failed to send. Tap to retry";"ios.ZDKRequests.createRequest.description.placeholder" = "Description";"ios.ZDKRequests.createRequest.emailfield.placeholder" = "Email";"ios.ZDKRequests.createRequest.error.request" = "Ticket failed to send";"ios.ZDKRequests.createRequest.failed.closed" = "This conversation has been closed.";"ios.ZDKRequests.createRequest.failed.delete" = "Delete";"ios.ZDKRequests.createRequest.failed.retry" = "Retry";"ios.ZDKRequests.createRequest.input.new" = "Write a message...";"ios.ZDKRequests.createRequest.input.reply" = "Reply...";"ios.ZDKRequests.createRequest.input.unsent.body" = "Going back will delete your message.\nAre you sure you want to delete it?";"ios.ZDKRequests.createRequest.input.unsent.title" = "Message not sent";"ios.ZDKRequests.createRequest.leaveAMessage.title" = "Leave a message";"ios.ZDKRequests.createRequest.message.sent" = "Sent";"ios.ZDKRequests.createRequest.messages.today" = "Today";"ios.ZDKRequests.createRequest.messages.yesterday" = "Yesterday";"ios.ZDKRequests.createRequest.name.placeholder" = "Name";"ios.ZDKRequests.createRequest.sending" = "Sending...";"ios.ZDKRequests.createRequest.submit.button" = "Send";"ios.ZDKRequests.createRequest.title" = "Contact us";"ios.ZDKRequests.leftBarButton.title_cancel" = "Cancel";"ios.ZDKRequests.requestList.cell.closed" = "Ticket Closed";"ios.ZDKRequests.requestList.cell.failed" = "Message failed";"ios.ZDKRequests.requestList.cell.me" = "Me";"ios.ZDKRequests.requestList.cell.responders" = "Re:";"ios.ZDKRequests.requestList.cell.seperator" = ", ";"ios.ZDKRequests.requestList.error" = "Failed to get tickets";"ios.ZDKRequests.requestList.title" = "My Tickets";"ios.ZDKRequests.requestListEmpty.button" = "Start A Conversation";"ios.ZDKRequests.requestListEmpty.subtitle" = "Conversations started from this app will be visible here";"ios.ZDKRequests.rightBarButton.title.contact" = "Contact us";"ios.sdk.ZDKHelpCenter.article.voting.title" = "Was this article helpful?";"ios.sdk.ZDKRequests.createRequest.attachment.fileTooBig" = "Max attachment size is %@mb";"ios.sdk.ZDKRequests.leftBarButton.close.title" = "Close";"ios.sdk.ZDKRequests.pushNotification.dismiss.title" = "Dismiss";"ios.sdk.ZDKRequests.pushNotification.open.title" = "Open";"ios.SupportEngine.greeting.message" = "Type a message and I will find someone who can help you.";"ios.SupportEngine.messageSend.errorMessage" = "Something went wrong and I wasn't able to send your message. Please try again later.";"ios.SupportEngine.messageSend.retry.button" = "Retry";"ios.SupportEngine.requestCreated.conversationsDisabled.message" = "Thank you. A message has been sent to the team. If a reply is needed, they will contact you on %@.";"ios.SupportEngine.requestCreated.conversationsEnabledMessage" = "Thank you. A message has been sent to the team. You can view this message and add additional details here:";"ios.SupportEngine.requestCreated.conversationsOff.message" = "Thank you. A message has been sent to the team. If a reply is needed, they will contact you by email.";"ios.SupportEngine.requestCreated.emailInvalid.message" = "Something isn't quite right with this address. Try re-entering it.";"ios.SupportEngine.requestCreated.emailPrompt.hint" = "Enter your email...";"ios.SupportEngine.requestCreated.emailPrompt.message" = "If a reply is needed, someone will contact you by email. What is your email address?";"ios.SupportEngine.requestCreated.emailValidationFailed.message" = "The email address you entered is incorrect. Enter a valid email address.";"ios.SupportEngine.requestCreated.requestList.button" = "View messages";

Supported languages

Strings in the Support SDK are already localized into the following languages:

Language codeLanguage
arArabic
bgBulgarian
csCzech
daDanish
deGerman
elGreek
en-GBBritish English
enAmerican English
esSpanish
fiFinnish
filFilipino
frFrench
heHebrew
hiHindi
huHungarian
idIndonesian
itItalian
jaJapanese
koKorean
msMalay
nbNorwegian
nlDutch
plPolish
pt-BRBrazilian Portuguese
ptPortuguese
roRomanian
ruRussian
svSwedish
thThai
trTurkish
viVietnamese
zh-HansSimplified Chinese
zh-HantTraditional Chinese