oops...sorry. What I mean is a code that will attach HTML tags on a plain text specifically from a <textarea>. I do hope I stated it right this time. ^^
If I understand right, you are saying that the user will input plain text into a text area, and you want to know the best way to display it with HTML formatting. Is this right? Usually there isn't a lot of formatting required, you might want to change special characters to character codes, and add paragraph tags or line breaks to maintain white space. Does this sound like what you want? Basically you would put the input through a series of replace statements that replace the given input with what output you want, like this:
- dim txt
-
txt = request.form("myTextBox1")
-
txt = replace(txt, "&", "&")
-
txt = replace(txt, chr(34), "&quot;")
-
txt = replace(txt, vbNewLine, "<br>"&vbNewLine)
-
response.write txt
You might want to look into "server.htmlencode" which is a function that does some of this (if I remember right it replaces the special characters), and depending on your needs, you might be able to use <pre> text input goes here </pre> tags.
Let me know if this helps.
Jared