Selected item populating in Select tag using JSTL?

I store Birthday Month in database as value using following code in JSP. Output code in JSP to show previously selected item using JSTL that I am using (which is not correct) `What I am getting from this code is value like 1 or 2 in select tag` Other Information: 1. I store birthday month as value like 1,2,3.. for Jan,Feb,Mar... in Database 2. I bring value of birthday month in request scope in Servlet using `request.setAttribute("birthdaymonth", user.getBirthdayMonth());` What i was expecting 1. When i show later JSP it should show previously stored birthday month as Jan,Feb, Mar and not 1,2,3 and also show other Option values including selected item as highlighted.

以上就是Selected item populating in Select tag using JSTL?的详细内容,更多请关注web前端其它相关文章!

赞(0) 打赏
未经允许不得转载:web前端首页 » JavaScript 答疑

评论 抢沙发

  • 昵称 (必填)
  • 邮箱 (必填)
  • 网址

前端开发相关广告投放 更专业 更精准