I’m designing a registration form in PHP using html. The form collects personal info from users some fields include the marital status, name of spouse, and the number of children. How can I code it such that whenever a user selects “Single” for his/her marital status, the textboxes for the name of spouse and number of children will be automatically disabled? All of this must be done without refreshing the page. Thanks!
I’m designing a registration form in PHP using html. The form collects personal info
Share
Assuming you are using drop down for marital status, use the
onchangeevent to capture the change in the drop down status