I have a complicated html form that dynamically created with java script.
I want to get the map of key-value pairs as a Map in java and store them.
here is my controller to get the submitted data.
@RequestMapping(value="/create", method=RequestMethod.POST,
consumes = MediaType.APPLICATION_FORM_URLENCODED_VALUE)
public String createRole(Hashmap<String, Object) keyVals) {
....
}
but my map is empty.
How can i get form data as a map of name-value pairs in Spring mvc controller?