struts:关于<global-exceptions>转发问题
<global-exceptions>
<exception key= "nullpointer " path= "/error.jsp " scope= "request " type= "
java.lang.NullPointerException "/>
</global-exceptions>
我在struts-config.xml添加了这个全局异常
问题:我在action中throw java.lang.
NullPointerException这个异常的时候,没有跳转到定的页面,最终还是跳转到了action跳转的页面(该action已经执行了异常),请问各位大虾,还需要怎么样,才能正确执行该全局异常
------解决方案--------------------lz可以把你action的代码贴出来看看!
------解决方案--------------------public ActionForward execute(ActionMapping actionMapping,
ActionForm actionForm, HttpServletRequest httpServletRequest,
HttpServletResponse httpServletResponse) throws Exception{