users@glassfish.java.net

Re: using default web module with static content in docroot

From: Bob Treacy <bobtreacy_at_yahoo.com>
Date: Tue, 14 Aug 2007 14:19:21 -0700 (PDT)

1. Make a simple webapp with this index.jsp

<%_at_page contentType="text/html"%>
<%_at_page pageEncoding="UTF-8"%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01
Transitional//EN"
   "http://www.w3.org/TR/html4/loose.dtd">

<html>
    <head>
        <meta http-equiv="Content-Type"
content="text/html; charset=UTF-8">
        <title>JSP Page</title>
    </head>
    <body>

        
            <img src="/mit-hmdc.banner.gif" />

    <h1>JSP Page</h1>
    
    
    </body>
</html>

2. Put any gif in docroot and rename it
"mit-hmdc.banner.gif" or else just change the <img src
... /> code above for your image file name
3. Make sure there is no default web module
configured. In the GlassFish console go to
Configuration->Http Service->Virtual Servers->server
Default Web Module should be blank
4. Browse to you webapp, you should see your image
5.Go back in the admin console to
Configuration->Http Service->Virtual Servers->server
Set Default Web Module to be your webapp
6. CLEAR YOUR BROWSER CACHE -so the image isn't loaded
from your cache
7. Browse to your webapp. The image is broken

--- Jan.Luehe_at_Sun.COM wrote:

> Bob Treacy wrote:
>
> >After I configured the virtual server to default to
> my
> >webapp, the images on our banners (which are stored
> in
> >docroot/images) are broken. Is there a way to fix
> >this?
> >
> >
>
> Can you please provide a reproducible test case?
>
> Jan
>
> >
>
>---------------------------------------------------------------------
> >To unsubscribe, e-mail:
> users-unsubscribe_at_glassfish.dev.java.net
> >For additional commands, e-mail:
> users-help_at_glassfish.dev.java.net
> >
> >
> >
>
>
---------------------------------------------------------------------
> To unsubscribe, e-mail:
> users-unsubscribe_at_glassfish.dev.java.net
> For additional commands, e-mail:
> users-help_at_glassfish.dev.java.net
>
>