About
To customize player text when embedding the player, add a translations object under the ui section of the KalturaPlayer.setup() configuration.
Configure player text
Add a translations object under the ui section of the player configuration.
Example
KalturaPlayer.setup({targetId: "kaltura_player",provider: {partnerId: <partnerId>,uiConfId: <uiConfId>},ui: {translations: {en: {kalturaLive: {offline_title: "Stream starting soon"},error: {default_error_title: "Oops, something went wrong"}}}}});
In this example:
- en specifies the language.
- kalturaLive and error identify the groups of player text to update.
- offline_title and default_error_title identify the text to replace.
- "Stream starting soon" and "Oops, something went wrong" are the replacement text displayed in the player.
Customize additional text
You can override any supported player text by adding additional translation groups and keys to the translations object.
For example, to customize the Play button label:
translations: {en: {controls: {play: "Start playback"}}}
Customize text for multiple languages
Add a translation object for each language you want to customize.
For example:
translations: {en: {controls: {play: "Play"}},es: {controls: {play: "Reproducir"}}}