1. Make sure that your eclipse version is javaee or you have installed the WTP plug-in.
2. Modify the. project file under the Eclipse project:
3. Add <natures> </natures>Java code?
| 1234 |
<Nature> org. Eclipse. WST. Common. Project. facet. Core. Nature </nature><Nature> org. Eclipse. WST. Common. modulecore. modulecorenature </nature><Nature> org. Eclipse. Jem. workbench. javaemfnature </nature> |
4. Add <buildspec> </buildspec>Java code?
| 12345678910 |
<Buildcommand> <Name> org. Eclipse. WST. Common. Project. facet. Core. Builder </Name> <Arguments> </Arguments> </Buildcommand> <Buildcommand> <Name> org. Eclipse. WST. validation. validationbuilder </Name> <Arguments> </Arguments> </Buildcommand> |
5. refresh the project, right-click the project, and choose Properties> Project facets> modify project, select Java and dynamic web module
Configure context root, content directory, and source code path