Win a copy of Programmer's Guide to Java SE 8 Oracle Certified Associate (OCA) this week in the OCAJP forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

How to create dynamic textboxes based on dropdown selection

 
Punit Jain
Ranch Hand
Posts: 1012
2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
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
Posts: 15385
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
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
Posts: 1012
2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
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..
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic