Here is how you usually read parameters in the controller:
@RequestMapping(value = "/getproducts", method = RequestMethod.GET) public ModelAndView getProduct(@RequestParam("productId") int prodId, Model model, HttpServletRequest request)
In alternative, the parameters can be part of the path in the URL. In that case you would retrieve information as follows:
@RequestMapping(value = "/product/{productId}", method = RequestMethod.GET) public @ResponseBody String getProduct( @PathVariable("productId") int productId)
Copyright © 2013 Welcome to the website of Davis Fiore. All Rights Reserved.