With some help of the people here, I've managed to get my project to call the default actions of the packages without the suffix .htm
. However, the request end up to index.jsp
inside the webapp folder if I call the URL without the forward slash.
<struts>
<constant name="struts.enable.DynamicMethodInvocation" value="false"/>
<constant name="struts.action.extension" value="htm,," />
<constant name="struts.objectFactory" value="spring" />
<constant name="struts.devMode" value="true"/>
...
<package name="home" namespace="/secured" extends="default">
<default-action-ref name="index" />
<action name="index" class="homeAction" method="execute">
<result name="success" type="tiles">home</result>
</action>
</package>
</struts>
Actions are executed if I call http://someurl/someproject/secured/
, but calling the URL http://someurl/someproject/secured
end up to the file index.jsp
.
What to do? Thanks
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…