• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

textbox text should not empty

 
Greenhorn
Posts: 19
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi pals

Please help me. i am using one text box and one enter button. i entered some text in the Textbox after i preshed enter button.The entered text in the textbox become empty. i have to see textbox text after i entered.

Thanks
Mallikarjuna
 
Sheriff
Posts: 67747
173
Mac Mac OS X IntelliJ IDE jQuery TypeScript Java iOS
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Put the text back when you return to the page using the value attribute.
 
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Reddy,
If you are using struts

use
<html:textarea property="question"rows="10" cols="43" ></html:textarea></p>

The text area values are persist when you click on button.
Try this,
 
Sheriff
Posts: 13411
Firefox Browser VI Editor Redhat
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by srinivasa v reddy:
Hi Reddy,
If you are using struts

use
<html:textarea property="question"rows="10" cols="43" ></html:textarea></p>

The text area values are persist when you click on button.
Try this,



Since JavaRanch has both a JSP and a Struts forum, and since the original poster has posted this in the JSP forum, it should be assumed that he/she isn't using Struts.

thippareddy,
How best to go about re-populating your form fields depends on how you've structured your application. For one example of how to do this, download the SimpleMVC war file from my site http://simple.souther.us.
 
reply
    Bookmark Topic Watch Topic
  • New Topic