No effect of & ldquo; Resultpath & rdquo; Constant in struts.xml

I have all the jsp pages (ex: index.jsp) in the WebContent folder and my application is working smoothly. Now, I created a folder “pages” inside WebContent, where I transferred all my jsp pages.

And I added the following line inside the
tags:


But still, its not searching for jsp inside the “pages” folder. I am getting:

HTTP Status 404 – /MyApplicationName/index.jsp

Where am I doing a mistake?

EDIT: The current structure of my application is as follows:

The welcome page is an action instead of a jsp page. The result page of this action is index.jsp. This action populates the dropdown menu and some other fields in index.jsp. Now, I want to keep index.jsp along with other jsp pages in the folder “WebContent/pages”. I have over 30 jsp pages in my application, and I don’t want to mention the full path of every jsp in the result-tag. Thats why I want to make use of the struts2 constant “struts.convention.result.path”

My question is, why the code I have mentioned above is not working?

Accessing index.jsp
directly bypasses all S2 request handling.

There’s no S2 or S2 Convention plugin involved, you’re just accessing a JSP page.

Hello, buddy!稿源:Hello, buddy! (源链) | 关于 | 阅读提示

本站遵循[CC BY-NC-SA 4.0]。如您有版权、意见投诉等问题,请通过eMail联系我们处理。
酷辣虫 » 综合编程 » No effect of & ldquo; Resultpath & rdquo; Constant in struts.xml

喜欢 (0)or分享给?

专业 x 专注 x 聚合 x 分享 CC BY-NC-SA 4.0

使用声明 | 英豪名录