javascript - How to retain input form values on validation fail spring MVC -


i in process of validating in input , want user input fields should retain in case of validation error

this how input fields are

<form:input path="firstname" class="text short" id="firstname" value="first name" name ="firstname"/> 

my problem value="first name", since on writing values user has filled in , can not change html , can add condition in above input box.

is there way solve issue?

i assume want display "first name" sort of placeholder until user enters in. in case, why don't use placeholder html5 attribute?


Comments

Popular posts from this blog

java - Play! framework 2.0: How to display multiple image? -

gmail - Is there any documentation for read-only access to the Google Contacts API? -

php - Controller/JToolBar not working in Joomla 2.5 -