Meaningless Drivel is fun!*
The moose likes Websphere and the fly likes Static Content problem Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Products » Websphere
Bookmark "Static Content problem" Watch "Static Content problem" New topic
Author

Static Content problem

Burcu Atalan
Greenhorn

Joined: Nov 02, 2005
Posts: 2
Hi,

I am using HTTPServer 2.0.4.2, WAS(Websphere Application Server) 5.0.2.10 on AIX 5.2

For performance issue, I set fileservingenabled=false, so my static content is served by HTTPServer.

But when I need to test application by accessing directly to application server via using HTTPTransportPort at URL(I bypass httpserver), since WAS do not serve static content(js, css,html,jpeg,etc.), application login page crushes.

Is there a way or setting to handle this problem?

I mean if I use virtual host,and access application using httpserver, http server will serve static content, but when I use appication server port, was server should serve static content.

Waiting for your suggestions.

Kind regards,
Scott Selikoff
Saloon Keeper

Joined: Oct 23, 2005
Posts: 3704
    
    5

Maybe I'm misunderstanding your situation, but since when does WAS not server static content? You can put the files you speak of (js,css,html,jpeg,etc.) inside a WAR file an access it once it is deployed in an EAR on the server.

Maybe I'm missing something.


My Blog: Down Home Country Coding with Scott Selikoff
Burcu Atalan
Greenhorn

Joined: Nov 02, 2005
Posts: 2
Hi,

Sorry for replying late.

I put static files in war file.

As far as I know(actually I test and see) in ibm-web-ext.xmi if you set

fileServingEnabled="false"

This setting prevents WAS from serving static content, and if you access your application using application server port which means bypassing web server(like http://10.5.6.12:9083/mysite/images/button.gif), application server cannot display images.

Thanks,
Patrick Finnegan
Ranch Hand

Joined: Mar 05, 2002
Posts: 179
"fileservingenabled=false" prevents WAS from serving static content. It should be set to true.

So for example:

http://10.5.6.12:80/images/button.gif - served by Apache from the doc root specified in the Apache virtual host definition.

http://10.5.6.12:80/mysite/images/button.gif - served by WAS through plugin redirection. "/images/button.gif" must exist in the WAS doc root for the app with the context root "mysite" i.e in the war file. Useful for apps where some of the static content is served by WAS and some by Apache.


So "http://10.5.6.12:9083/mysite/images/button.gif" should also work with "fileservingenabled=true"
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Static Content problem