In the next Spring 3.1 action, I have to do some things and add the attribute to the POST request and then redirect it to the external URL via POST (I cannot use GET).
@RequestMapping(value = "/selectCUAA", method = RequestMethod.POST) public ModelAndView selectCUAA(@RequestParam(value="userID", required=true) String cuaa, ModelMap model) { //query & other... model.addAttribute(PARAM_NAME_USER, cuaa); model.addAttribute(... , ...); return new ModelAndView("redirect:http://www.externalURL.com/", model); }
But with this code uses the GET method (attributes are added to the http://www.externalURL.com/ ). How can I use the POST method? It is required for an external URL.
source share