Alerting Special Characters using jQuery/JavaScript

后端 未结 3 965
陌清茗
陌清茗 2021-02-08 03:08

How do i display a string with Special Characters like € in a Javascript/jQuery alert?

eg: I want to display a message box with \"The Price is €10\"

But whe

3条回答
  •  無奈伤痛
    2021-02-08 03:47

    Use this as the alert. Works fine for me.

    alert(' The Price is \u20AC 10');
    

    The description is here : http://leftlogic.com/projects/entity-lookup/

提交回复
热议问题