Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我使用我的 Spring 工具套件创建了一个示例 Maven MVC 项目,但无法部署到 tomcat。
问题是当我右键单击项目并单击“运行方式”时,我没有看到“在服务器上运行”选项。
选择属性项目方面后,我尝试将项目更改为动态 Web 模块
但得到错误,“动态 web 模块 3.0 需要 Java 1.6 或更高版本”
如何让我的项目在 Tomcat 中运行?
为 Java 1.6 编译您的 Maven 项目。将此添加到您的pom.xml:
pom.xml
<build> <plugins> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-compiler-plugin</artifactId> <configuration> <source>1.6</source> <target>1.6</target> </configuration> </plugin> </plugins> </build>
当我从浏览器运行我的 WCF REST 方法时,我收到 一个:在浏览器中返回 WCF REST 服务时的 xml 元素前面?任何人都见过这个并知道它为什么会发生?我期待格式化的元素
<