Ok, first let me say that all the Chr(34) is a bad thing. It makes the
code hard to read, and also makes it so you are concatinating a bunch of
strings, which is slow. Instead, use 2 double quotes whereever you want
a double quote in your string. Same goes for the vbCRLF's. They make
it harder to read and also require more concatinating. Also, you would
be better off using Response.Write on each item instead of concatinating
them all into one big string and then writing them out. From the first
message you sent, you were missing a ">" to close the TEXTAREA element
start tag. In addition, you should be sure the variables don't contain
any HTML characters (like < or >) and HTMLEncode them just to be safe.
Try this code:
sType=Request.Form("Type")
Select Case (sType)
...
...
Case "TA":
Response.Write(" <tr>")
Response.Write(vbCRLF)
Response.Write(" <td align=""right""
valign=""top"">")
Response.Write( Server.HTMLEncode(sLabel) )
Response.Write(" </td>")
Response.Write(vbCRLF)
Response.Write(" <td valign=""top"">")
Response.Write(vbCRLF)
Response.Write(" <textarea rows=""5""
cols=""25"" name=""")
Response.Write( Server.HTMLEncode(sName) )
Response.Write(""" wrap=""virtual"">")
' Anything you want in the text area, add here. Dont forget to
HTMLEncode it.
Response.Write(" </textarea>")
Response.Write(vbCRLF)
Response.Write(" </td>")
Response.Write(vbCRLF)
Response.Write(" </tr>")
Response.Write(vbCRLF)
...
...
Hope this helps.
Peter
> -----Original Message-----
> From: Christopher Cote [mailto:cotec@s...]
> Sent: Monday, February 04, 2002 3:57 PM
> To: Pro ASP HowTo
> Subject: [proasp_howto] Re: Need a second pair of eyes to look at
> something
>
>
> Well, guys, I seem to have found a solution, though it
> doesn't make any
> sense. Here is what I found:
>
> If I delete the </textarea> from the string, the string
> will display
> the whole string that is on those 3 lines. If I add the </textarea>
> string back in, though, the textbox stops displaying text
> before that part
> of the string and exits the select statement without finishing going
> through the loop.
>
> This makes no sense to me since this should be just a literal string,
> shouldn't it. The textarea finishes the string right before
> the < sign.
> Can anyone explain why this happened? And if so, do you know
> how I can
> somehow get the </textarea> back into the string?
> $subst('Email.Unsub').
>