IDEA 调试项目 java.lang.ClassNotFoundException: org.springframework.web.context.ContextLoaderListener
IDEA 调试项目 出现java.lang.ClassNotFoundException: org.springframework.web.context.ContextLoaderListener
创建Web项目是 tomacat启动时出现此错误,
1.先检查是否包含spring-web.jar 包
2.然后检查IDEA配置;
File > Project Structure > Artifacts > 在右侧Output Layout右击项目名,选择Put into Output Root,见下面截图:
执行后,在WEB-INF在增加了lib目录,里面是项目引用的jar包,点击OK。
重新启动Tomcat,这次成功发布。