Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

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.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8608659
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T03:40:20+00:00 2026-06-12T03:40:20+00:00

Spring 3.0 (form:select, form:option(s) ) tag library supports rendering HTML 5 data-* attributes using

  • 0

Spring 3.0 (form:select, form:option(s) ) tag library supports rendering HTML 5 data-* attributes using a bean’s property? If yes , an example would help.
Background : I am developing a Spring MVC app and using Bootstarp css and JS and spring provided tags. Need to use HTML 5 data-* attributes to keep additional data with dropdowns options. Based upon the user selection in one of the dropdown , I want update further dropdowns and I want to avoid AJAX calls to fetch options for next dropdown since I have the data during page load.
I understand JQuery has attribute support but that would require javascript code execution on page load, so looking for HTML 5 support. Any other suggestions to handle this are welcome.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-12T03:40:22+00:00Added an answer on June 12, 2026 at 3:40 am

    Data-* attributes are supported on Spring 3.0 form tags (along with any validly-named custom attribute you specify, I believe). You can also use the value of a bean’s property as the attribute value, e.g.

    <form:input data-test="${myBean.propertyName}" path="propertyName" />
    

    To answer the second part of your question, where you ask if there’s a way to get the Spring form tag library to populate the data-* attributes with the contents of the bean’s property that you specify, this does not happen automatically: you would need to write a custom tag that does this.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm using Spring's form tag library in a Spring MVC application that I am
I have HTML form with lots of select and input fields, using it a
I'm using Spring. I've got a JSP with a form:select in it displaying the
On my MVC spring application I send a form to a page using post
Form is not giving value on controller for sql.date i am using spring and
I'm validating a form using the Validator interface with Spring MVC 3.0.2 using SimpleFormController
I'm trying to do a partial rendering of my web site, using spring mvc
Im trying to get a value or a text from the select option tag
I 'm dynamically loading spring checkbox tags according to changes in select tag. But
I have a table, using display tag, in my application, that is using spring

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.