This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes HTML, CSS and JavaScript and the fly likes How to create dynamic textboxes based on dropdown selection Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "How to create dynamic textboxes based on dropdown selection" Watch "How to create dynamic textboxes based on dropdown selection" New topic
Author

How to create dynamic textboxes based on dropdown selection

Punit Jain
Ranch Hand

Joined: Aug 20, 2011
Posts: 980
    
    2
Hello everyone,
my problem is: I want to show textboxes on a form as the dropdown selection, i mean if anyone selected 5 in the dropdown, 5 textboxes should display below.
can anyone tell me how can i do this using js??
Eric Pascarello
author
Rancher

Joined: Nov 08, 2001
Posts: 15376
    
    6
document.createElement and appendChild() are what you need. OR if there is a limited number of selections,, you can show and hide.

Eric
Punit Jain
Ranch Hand

Joined: Aug 20, 2011
Posts: 980
    
    2
Eric Pascarello wrote:document.createElement and appendChild() are what you need. OR if there is a limited number of selections,, you can show and hide.

Eric



Yes, i got it.
Thank you..
 
wood burning stoves
 
subject: How to create dynamic textboxes based on dropdown selection
 
Similar Threads
Struts 1.2 array validation
html:select with multiple = true????
Displaying the input fields on selection
Associating form fields with Vectors/Beans
how to add multiple selection from dropdown list