springmvc传值到html页面,如何取值?
publicModelAndViewgetGraphs(HttpServletRequestrequest,HttpServletResponseresponse)thr...
public ModelAndView getGraphs(HttpServletRequest request,HttpServletResponse response) throws Exception{
ModelAndView mav = new ModelAndView();
Return ret = new Return(true);
String name = request.getParameter("name");
try {
ret.setData(monMmdbViewModService.getGraph(name));
ret.setMessage("success");
} catch (Exception me) {
log.eLog(me);
ret.setSuccess(false).setMessage(me.getMessage());
}
mav.addObject("ret",ret);
mav.setViewName("page/edit/index");
return mav;
}
如果是jsp的话可以通过EL表达式"${ret}"就能取到值
跪求html如何取值..... 展开
ModelAndView mav = new ModelAndView();
Return ret = new Return(true);
String name = request.getParameter("name");
try {
ret.setData(monMmdbViewModService.getGraph(name));
ret.setMessage("success");
} catch (Exception me) {
log.eLog(me);
ret.setSuccess(false).setMessage(me.getMessage());
}
mav.addObject("ret",ret);
mav.setViewName("page/edit/index");
return mav;
}
如果是jsp的话可以通过EL表达式"${ret}"就能取到值
跪求html如何取值..... 展开
2个回答
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询