ASP HTMLEncode Attribute
Definition and Usage
The HTMLEncode method applies HTML encoding to a specified string.
syntax
Server.HTMLEncode(string)
parameters | description |
---|---|
string | Required. The string to be encoded. |
Example
Script:
<% response.write(Server.HTMLEncode("The image tag: <img>")) %>
Output:
The image tag: <img>
Browser Output:
The image tag: <img>