How do I display html and asp tags and code on an asp page as text(without executing)?
I'm able to use char(num) to get the html tags as text but not the asp "<%%>" 's
Printable View
How do I display html and asp tags and code on an asp page as text(without executing)?
I'm able to use char(num) to get the html tags as text but not the asp "<%%>" 's
For the HTML, you can use the <plaintext> tags:
<plaintext>This is the text and/or html you want to display</plaintext>
For the ASP, simply use the URLEncoded versions of the <% and %> to display the "<%","%>" tags:
<%<br>
for i = 1 to 10<br>
Response.Write "hello world"<br>
next<br>
%><br>
Hope that helps...
JeffB
Hello,
Use the HTMLEncode() method. It will work.
Bye and have a good time programming.