Haulyn R. Jason wrote:
> Hi,all
> I set struts-action-extension="" for no extension as "action" or "do" by
> default for struts2, and mapping all url to struts2 dispatcher as "/*".
> But, the problem is I can not access any jsp, html,css and js files. The
> page display:there are no action mapping for XXX.jsp action.
> Should any one give me some suggestions or referenced links? Always
> thanks very much.
>
>   

I'm not sure if your setting is interpreted as blank, not set (default)
or null.

Did your jsp, html, css and js work before you made that change?

The process works like this:
1. the container sees the request and maps it to the Strust2
FilterDispatcher because it matches /*
2. the FilterDispatcher checks whether the request contains a known
action extension, and if so, invokes the ActionMapper
3. If the ActionMapper didn't find anything, the FilterDispatcher checks
if there's struts static resource for the request (if
serve.static.resource=true)
4. If nothing matched, the filter does nothing
5. If nothing has processed the request, the container eventually
invokes the Default Servlet (and JSP handling, other file handling)

So there's two possible problems:
a. the FilterDispatcher thinks it can handle everything and tries to,
causing an error; or
b. there is a configuration problem with the container (eg. the default
servlet is disabled or the request never reached the container).

In case it is a, I would try the following settings:

struts.action.extension=,,action

Note the double comma. That means a blank (no extension), or .action
extension. The double-comma ensures blank isn't trimmed as whitespace.

Hope that helps,
Jeromy Evans



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to