Open
Conversation
原因:struct.xml的位置不正确,不应该放在外面的(根目录)src里而是需要在web模块下新建一个src文件夹,把它标记为source 文件夹,然后把所有的Java包和struct.xml文件移动到这个目录下 修正: 1.在web模块下新建一个src文件夹并标记为source root 2.移动/src/guoyachen到/web/src/guoyachen 3.移动/src/struct.xml到/web/src/struct.xml 4.在file-project structure下的artifact里,在web-inf下新建lib文件夹存放jar包,右键点击avaliable elements下的条目,选择put into output root,记住,如果发现有找不到class的报错,重复次步骤即可,同时清除web-inf页面下的lib文件夹里有标红的jar 5.在file-project structure下的facets选项中,选择struct2,在右边点击铅笔图标,重新选择struct.xml的位置,具体的看这篇文章:https://www.jianshu.com/p/3a2ca7ee6b82 6.在pom.xml下条件build模块,强行规定jdk版本为1.8,修复由于依赖变动导致的jdk版本的错乱 7.添加${pageContext.request.contextPath}/到register.jsp下的action地址上
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
原因:struct.xml的位置不正确,不应该放在外面的(根目录)src里而是需要在web模块下新建一个src文件夹,把它标记为source
文件夹,然后把所有的Java包和struct.xml文件移动到这个目录下
修正:
1.在web模块下新建一个src文件夹并标记为source root
2.移动/src/guoyachen到/web/src/guoyachen
3.移动/src/struct.xml到/web/src/struct.xml
4.在file-project structure下的artifact里,在web-inf下新建lib文件夹存放jar包,右键点击avaliable elements下的条目,选择put into output root,记住,如果发现有找不到class的报错,重复次步骤即可,同时清除web-inf页面下的lib文件夹里有标红的jar
5.在file-project structure下的facets选项中,选择struct2,在右边点击铅笔图标,重新选择struct.xml的位置,具体的看这篇文章
6.在pom.xml下条件build模块,强行规定jdk版本为1.8,修复由于依赖变动导致的jdk版本的错乱
7.添加${pageContext.request.contextPath}/到register.jsp下的action地址上