users@glassfish.java.net

Re: Path to custom default error page resources

From: Amy Roh <amy.roh_at_oracle.com>
Date: Wed, 18 Jan 2012 12:06:26 -0800

I would put the custom default error page and image files in the docroot
directory (domains/domain1/docroot & domains/domain1/docroot/images) and
define the send-error_1 property with a value
"path=${com.sun.aas.instanceRoot}/docroot/404.html code=404".

 From your error page, you can refer to your images files <img
src="images/..."/>

hth,
Amy

On 1/18/12 7:01 AM, forums_at_java.net wrote:
> I have successfully made a custom default error page for 404 by adding
> my own
> html file to <domain>/config/my-errorpage.html , and added a property
> named
> 'send-error_1' with the vaule 'code=404 path=my-errorpage.html' in the
> admin console under Configurations > Server-config > Virtual servers >
> server
> .
>
> This works.
>
> But my-errorpage.html contains <img src="somepath/my-image.png"/> (and
> also
> CSS background URL specs), and I can't figure out how I should specify
> the
> path, or where I should put the image files. [pulling my hair]
>
> Preferably, I would like to keep the image files with the html file.
>
> Is this possible? How?
>
>
>
>
> --
>
> [Message sent by forum member 'tmpsa']
>
> View Post: http://forums.java.net/node/882803
>
>