How to populate ddropdown list in a web page in struts2 from database. The items of the drop down will be taken from database.
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
For creating list in struts2, we can use implement Preparable.
For jsp, use:
Preparable interface will call prepareCountryList method before calling countryList and jsp will be prepopulated. You can populate as many drop down list using single method in struts2.