Get a first look at what's coming. The Developer Passport Australia Release Preview kicks off March 12. Dive in! 

Translating the alert message in catalog client script to another language

Chetan Marathe
Tera Contributor

Hello, 

 

I wrote a catalog client script to get an error message.

In that I used alert(); to get that message. 

Now I want to translate the message into another language.

Can you please help with this?

I have also tried to create a Key in Messages>> in>> System Localization.

 

Thanks,

Chetan Marathe

8 REPLIES 8

Not applicable

Raghav Sharma24
Giga Patron

1. use below code instead of alert.

getMessage('alert_message', function(msg){alert(msg);});

 2. create an entry in "sys_ui_message" table for the alert message you are passing above in required language.


Please mark the answer correct/helpful accordingly.

This worked like a charm, thanks!

This works, thanks!