navigation
a webmaster learning community
     Home    Register     Search      Help      Login    
Sponsors

Shopping Cart Software
Ecommerce software integrated into Frontpage, Dreamweaver and Golive templates. No monthly fees and available in ASP and PHP versions.

Website Templates
We also have a wide selection of Dreamweaver, Expression Web and Frontpage templates as well as webmaster tools and CSS layouts.

Frontpage website templates
Creative Website Templates for FrontPage, Dreamweaver, Flash, SwishMax

Search Forums
 

Advanced search
Recent Posts

 Todays Posts
 Most Active posts
 Posts since last visit
 My Recent Posts
 Mark posts read

 

HTML in a Textarea Tag

 
View related threads: (in this forum | in all forums)

Logged in as: Guest
Users viewing this topic: none
Printable Version 

All Forums >> Web Development >> ASP and Database >> HTML in a Textarea Tag
Page: [1]
 
Aaron Edwards

 

Posts: 2
Joined: 8/15/2003
Status: offline

 
HTML in a Textarea Tag - 9/10/2003 11:37:08   
I'm trying to pass HTML to an ASP script via a TEXTAREA tag but for some reason, once the form gets submitted, everything between a < and a > gets swallowed. This seems like an HTML problem, because I print out the variable as soon as it gets into ASP land and it's already truncated.

Here's the code if you want to check it out ...

Default.asp:

<%
If Request("action") = "process" then
ProcessForm
Else
DisplayForm
End If
Response.End

Sub DisplayForm
%>
<form name="someform" Action="Default.asp?action=process" method="post">
<textarea cols="40" rows=22 name="txtBody">Put some sample HTML code in here. </textarea>
<input type="submit" value="Send!">
</form>
<%
End Sub


Sub ProcessForm
Dim txtBody
txtBody=Request.Form("txtBody")
Response.write txtBody
End Sub
%>
rdouglass

 

Posts: 9280
From: Biddeford, ME USA
Status: offline

 
RE: HTML in a Textarea Tag - 9/10/2003 15:28:19   
quote:

txtBody=Request.Form("txtBody")


Have you tried anything like this:

txtBody=Replace(Request.Form("txtBody"),"<","&lt;")
txtBody=Replace(txtBody,">","&gt;")

Just a shot...:)

< Message edited by rdouglass -- 9/11/2003 8:24:18 AM >


_____________________________

Don't take you're eye off your final destination.

ASP Checkbox Function Tutorial.

(in reply to Aaron Edwards)
Page:   [1]

All Forums >> Web Development >> ASP and Database >> HTML in a Textarea Tag
Page: [1]
Jump to: 1





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts