form field formatting

S

Sharon Gano

I used the following method to display a form field that was passed from a
previous page:

<% = request("field_name") %>

This method displays the field contents inside of a text box. Is there any
way to display the field contents as just flat text instead?
 
T

Thomas A. Rowe

<%=Request.Form("Fieldname")%>

--
==============================================
Thomas A. Rowe (Microsoft MVP - FrontPage)
==============================================
If you feel your current issue is a results of installing
a Service Pack or security update, please contact
Microsoft Product Support Services:
http://support.microsoft.com
If the problem can be shown to have been caused by a
security update, then there is usually no charge for the call.
==============================================
 
M

MD Websunlimited

Sharon,

It will only display it inside a text box if it is used as the value of a text box, e.g.,

<input type="text" value="<% =request("field_name") %>" name="mytextbox" />

to display as plain text

<span class="plainText" ><%=request("field_name") %></span>

The reason for embedding it in a span tag is that it allows you to use CSS to format the text if you wish.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top