web.xml中没看出异常啊?
比如输入http://localhost:8080/dyn2/dy...
会自动调整到http://localhost:8080/dyn2/login
http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"> Dynamic Matrix powered by Spring Dynamic Matrix webAppRootKey dyn2.root log4jConfigLocation /WEB-INF/log4j.properties contextConfigLocation /WEB-INF/applicationContext.xml characterEncodingFilter org.springframework.web.filter.CharacterEncodingFilter encoding utf8 springSecurityFilterChain org.springframework.web.filter.DelegatingFilterProxy characterEncodingFilter /* springSecurityFilterChain /* org.springframework.web.util.Log4jConfigListener org.springframework.web.context.ContextLoaderListener org.springframework.web.util.HttpSessionMutexListener dynMatrix org.springframework.web.servlet.DispatcherServlet 1 dynMatrix / 60 403 /errors/403.html
这是controller
@RequestMapping(value="/create",method=RequestMethod.GET) public String getCreateForm(Model model){ this.addEnableMap(model); model.addAttribute(new WebUser()); //加载分类 String cwhere = " where type_parent_id=0"; ListcheckListType = checkLMDao.getCheckListTypeByWhere(cwhere, 0, 0); model.addAttribute("checkListType", checkListType); return "createUserForm"; }
可能是这个过滤器拦截到了你的请求
项目是你一个人在负责吗?如果不是这种问题最好问同一个项目组的同事
请求这条地址可能需要一些登录信息什么的做验证,在ajax里请求会把这些信息传过去,
你直接浏览器输入不带有这些信息就会被security过滤器给拦截转发到登录页面了。