Online: 15567
Following are the list of characters that can be used to show the special characters to the users.
<script>
function AlertMe() {
alert("\"This sentence has a double quote \", being displayed using escape character.!");
}
</script>
<input type="button" id="btnAlert" onclick="AlertMe()" value="Show Alert" />
In the above code, alert will show “(double quotes) character in the alert message that is being displayed by using the escape character “\”.
OUTPUT