views:

20

answers:

0

I'm getting a tomcat 404 error in my application when I hit a url with a dot.

Something like http://www.example.com/homePage.ac

I've got a default action defined and it catches missing actions, but it doesn't seem to catch these type of URLs.

I tried defining a page in web.xml, but my error page isn't a static page, it's another action, so when the application receives one of these URLs I need it to redirect to the my missing.action

Edit:

<default-action-ref name="noHit"/>

<action name="noHit" class="com.classes.actions.MissingAction">
    <result name="success" type="freemarker">freemarker/noHit.ftl</result>
</action>

I ended up just using a static page that mirrored what my other action had. I guess you could put a redirect in the static page as well.