wood burning stoves 2.0*
The moose likes Struts and the fly likes how to display a textbox when a radio button is selected Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "how to display a textbox when a radio button is selected" Watch "how to display a textbox when a radio button is selected" New topic
Author

how to display a textbox when a radio button is selected

shyama sai
Greenhorn

Joined: Dec 29, 2009
Posts: 1
hi, i'm new to struts....i have two radio buttons one named A and other named B. I want to display a textbox when radio button A is selected. Please help me how to do it!!!
Ankit Garg
Sheriff

Joined: Aug 03, 2008
Posts: 9291
    
  17

Hi Shyama welcome to javaranch.

This is not hard to achieve if you know basic javascript and Document Object Model. You just need to handle the onclick event of the radio button...


SCJP 6 | SCWCD 5 | Javaranch SCJP FAQ | SCWCD Links
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: how to display a textbox when a radio button is selected
 
Similar Threads
Radio buttons
How to populate a value in text box
exract the values of a row which is dynamically generated
Radio buttons(URGENT)
JSF Problem for RadiButtons (Jdeveloper 11 and ADF)