摘要:
首先,这个标签是3.0后引入的;如果3.0还不能解析,则是xml配置文件mvc头没有引入,在*-servlet.xml头信息里加入如下:xmlns:mvc="http://www.springframework.org/schema/mvc"http://www.springframework.org/schema/mvc http://www.springframework.org/schema/mvc/spring-mvc-3.0.xsd另外在spring中返回json时,需要在controller前配置<mvc:annotation-driven/>,还要 阅读全文
posted @ 2012-03-26 16:28
xiong2012
阅读(14985)
评论(0)
推荐(0)
摘要:
简单Spring MVC 列子:http://www.blogjava.net/pengo/archive/2010/11/28/339229.html@controller、@RequestMapping使用说明:http://starscream.iteye.com/blog/1063966Spring 返回json列子:在controller中的方法前面加@ResponseBody就可以了@RequestMapping(value="test1.htm",method=RequestMethod.GET) public @ResponseBody Shop getSh 阅读全文
posted @ 2012-03-26 11:16
xiong2012
阅读(376)
评论(0)
推荐(0)
浙公网安备 33010602011771号