eclipse windows中的Tomcat webapps目录

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/13909082/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-09-19 19:37:42  来源:igfitidea点击:

Tomcat webapps directory in windows

eclipsejsptomcatweb-applicationsservlets

提问by ravi

I am right now using eclipse to develop a simple web application and I am using Tomcat as web server. I have configured Tomcat in Eclipse and my application runs fine.

我现在正在使用 eclipse 来开发一个简单的 Web 应用程序,我正在使用 Tomcat 作为 Web 服务器。我已经在 Eclipse 中配置了 Tomcat,我的应用程序运行良好。

My question is: where does Tomcat store the web app and in which folder does it store the classes?I wanted to check the JSP to servlet conversion and wanted to verify how that converted file looks like and I am trying to find where exactly Tomcat stores the web app. I went into the webapps folder where Tomcat was extracted but my webapp is not in that folder. Can someone tell where I can find the converted JSPs?

我的问题是:Tomcat 在哪里存储 Web 应用程序以及它在哪个文件夹中存储类?我想检查 JSP 到 servlet 的转换,并想验证转换后的文件的样子,我试图找到 Tomcat 存储 Web 应用程序的确切位置。我进入了提取 Tomcat 的 webapps 文件夹,但我的 webapp 不在该文件夹中。有人能告诉我在哪里可以找到转换后的 JSP 吗?

回答by Ahmad Y. Saleh

right-click on the web project and select Run Asthen Run Configurations...

右键单击 Web 项目并选择Run As然后Run Configurations...

From the Argumentstab, the tomcat deploy path is provided as a VM argumentwith the name -Dwtp.deploy

Arguments选项卡中,tomcat 部署路径作为VM 参数提供,名称为-Dwtp.deploy

回答by ravi

Found out the location. Double clicked on tomcat server inside eclipse and got the server path. something like this .. C:\EclipseWorkspace.metadata.plugins\org.eclipse.wst.server.core\tmp0

找到了位置。在eclipse里面双击tomcat server,得到服务器路径。像这样.. C:\EclipseWorkspace.metadata.plugins\org.eclipse.wst.server.core\tmp0

The location of the web app will be in the .metadata folder inside eclipse workspace (chk server path) and the converted jsp files can be found in location as given below.

Web 应用程序的位置将位于 eclipse 工作区(chk 服务器路径)内的 .metadata 文件夹中,并且可以在如下位置找到转换后的 jsp 文件。

serverpath\work\Catalina\localhost\loginApp\org\apache\jsp

serverpath\work\Catalina\localhost\loginApp\org\apache\jsp

@Admins ... This question can be closed or what ever action needs to be taken.

@Admins ... 这个问题可以关闭或需要采取什么行动。

Thanks.

谢谢。