how to translate the html5 placeholders dynamically

前端 未结 5 1189
星月不相逢
星月不相逢 2021-02-01 13:41

I\'m using angular-translate to translate the page content in to different languages.


         


        
5条回答
  •  再見小時候
    2021-02-01 14:29

    +ira 's solution works for me.

    
    

    where username is the key for the translation. So that translation JSON line might look like the following in Spanish

    "USERNAME": "Nombre",
    

    The two together puts Nombre as a placeholder inside the input box

提交回复
热议问题