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.
我有一个问题,将视图 (.jsp) 文件放在 Web 应用程序中的位置。有点混淆它可能位于 WEB-INF 文件夹内或 WEB-INF 文件夹外。
许多spring项目视图(.jsp)文件通过创建子文件夹存储在WEB-INF文件夹中。
我看到了很多示例 spring 项目,它在 WEB-INF 文件夹中包含 .jsp 文件。那么我的问题的最佳做法是什么
阿米拉
如果您的应用程序是,servlet centric那么您可以在 WEB-INF 下添加 .jsp 文件并通过 .jsp 请求它们RequestDispatcher。如果不是,则将 .jsp 放在 .jsp 之外WEB-INF。
servlet centric
RequestDispatcher
WEB-INF