javagirl
javagirl

Reputation: 1675

wicket 1.5 + error-page + cannot find the related path to css resources

I have the next problem with wicket and standard error handling:

all the css files are stored as java resources, near the html pages. It's working fine. But, when I added the 404 error handling in the web.xml so that any not-found-url is treating as redirect to my PageNotFound.class - the paths to css in this page are broken. it's writes it as

   <wicket:link>
        <link rel="stylesheet" type="text/css" href="../../wicket/resource/com.web.common.PageNotFound/css/common.css"/>
 </wicket:link>

instead of

 <wicket:link>
    <link rel="stylesheet" type="text/css" href="wicket/resource/com.web.common.PageNotFound/css/common.css"/>
 </wicket:link>

(which is working fine, and appeared if I point directly to this PageNotFound page)

So the questions is - why only when error is handled it adds additional useless "../../" to css path?

I did all as it is described here (HTTP Error pages part): adding custom error pages using wicket

Upvotes: 0

Views: 725

Answers (1)

bernie
bernie

Reputation: 10400

Have a look at https://issues.apache.org/jira/browse/WICKET-3602. This might be the cause of your problem.

Upvotes: 1

Related Questions