If you really want the browser not to cache images, you are better off
putting a timestamp on
the end of the requests - as no-cache does not convince every browser
all of the time...
ie: http://localhost/image.gif?78927842303
On Mar 2, 2005, at 6:46 AM, [EMAIL PROTECTED] wrote:
Is there a way
Is there a way to alter the default HTTP header fields when a request is
made to Tomcat for static content? I would like to be able to add the
Cache-Control general header field with value no-cache when serving
images so they are not cached on the client side.
Can anyone please help? I've tried
Does there exist a howto on serving static content with Tomcat? Even
better would be one that shows how to do this with Tomcat+JBoss.
Searching Google seems to turn up lots of hits that say basically, Use
Apache instead of Tomcat to serve static content. I really need to
get this working
Tomcat will serve static content, pretty much out of the box. What is
the problem you're experiencing ?
-Original Message-
From: Matthew Hixson [mailto:[EMAIL PROTECTED]
Sent: Friday, July 09, 2004 3:27 PM
To: Tomcat Users List
Subject: serving static content
Does there exist
-
From: Matthew Hixson [mailto:[EMAIL PROTECTED]
Sent: Friday, July 09, 2004 3:27 PM
To: Tomcat Users List
Subject: serving static content
Does there exist a howto on serving static content with Tomcat? Even
better would be one that shows how to do this with Tomcat+JBoss.
Searching Google seems
?
-Original Message-
From: Matthew Hixson [mailto:[EMAIL PROTECTED]
Sent: Friday, July 09, 2004 3:27 PM
To: Tomcat Users List
Subject: serving static content
Does there exist a howto on serving static content with Tomcat? Even
better would be one that shows how to do this with Tomcat+JBoss
PLaese no send emailthank you
-Mensaje original-
De: Matthew Hixson [mailto:[EMAIL PROTECTED]
Enviado el: Viernes 9 de Julio de 2004 15:54
Para: Tomcat Users List
Asunto: Re: serving static content
I'm trying to serve images from /usr/local/watermarks. The URL should
be http
recipient, please notify the sender immediately by reply
e-mail and
delete all copies of this message and attachments. Thank you.
-Original Message-
From: Matthew Hixson [mailto:[EMAIL PROTECTED]
Sent: Fri 09 July 2004 4:54 pm
To: Tomcat Users List
Subject: Re: serving static content
I'm
To unsubscribe, e-mail: [EMAIL PROTECTED]
!
-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Sent: Friday, July 09, 2004 3:57 PM
To: [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Subject: RE: serving static content
PLaese no send emailthank you
: serving static content
I'm trying to serve images from /usr/local/watermarks. The
URL should
be http://mymachine.com/watermarks/. I've tried adding a Context to
server.xml, but every time I try to access
http://mymachine.com/watermarks I get a 404 message:
The requested resource
and attachments. Thank you.
-Original Message-
From: Matthew Hixson [mailto:[EMAIL PROTECTED]
Sent: Fri 09 July 2004 4:59 pm
To: Tomcat Users List
Subject: Re: serving static content
Host name=localhost debug=99
unpackWARs=true autoDeploy=true
xmlValidation=false
: serving static content
Host name=localhost debug=99
unpackWARs=true autoDeploy=true
xmlValidation=false xmlNamespaceAware=false
!-- ADD WATERMARKS DIRECTORY --
Context path=/watermarks appBase=
docBase=/usr/local/watermarks
debug=99
recipient, please notify the sender immediately by reply e-mail and
delete all copies of this message and attachments. Thank you.
-Original Message-
From: Matthew Hixson [mailto:[EMAIL PROTECTED]
Sent: Fri 09 July 2004 5:09 pm
To: Tomcat Users List
Subject: Re: serving static content
I
PROTECTED]
Sent: Fri 09 July 2004 5:09 pm
To: Tomcat Users List
Subject: Re: serving static content
I actually did try this already. I have a WEB-INF with a web.xml in
it. The entire web.xml is:
---
?xml version=1.0?
!DOCTYPE web-app PUBLIC
-//Sun Microsystems, Inc.//DTD Web
. Thank you.
-Original Message-
From: Matthew Hixson [mailto:[EMAIL PROTECTED]
Sent: Fri 09 July 2004 5:09 pm
To: Tomcat Users List
Subject: Re: serving static content
I actually did try this already. I have a WEB-INF with a
web.xml in
it. The entire web.xml
it in the manager. Or it might be that tomcat, for
whatever reason, isn't starting the context.
--mikej
-=-
mike jackson
[EMAIL PROTECTED]
-Original Message-
From: Matthew Hixson [mailto:[EMAIL PROTECTED]
Sent: Friday, July 09, 2004 2:48 PM
To: Tomcat Users List
Subject: Re: serving static content
On Fri, Jul 09, 2004 at 01:58:40PM -0700, Matthew Hixson wrote:
: Host name=localhost debug=99
:unpackWARs=true autoDeploy=true
:xmlValidation=false xmlNamespaceAware=false
:
: Context path=/watermarks appBase=
: docBase=/usr/local/watermarks
:
Got it! My colleague discovered this post:
http://www.jboss.org/index.html?module=bbop=viewtopicp=3840204#3840204
I put the defaultWebXml attribute into the Context and pointed it to
the stock global Tomcat web.xml file. Now Tomcat thinks that
/watermarks/ is a real webapp apparently and files
Hi all,
I've used tomcat quite a bit before, but always as a
connector to another web server. I'm running Tomcat
5.0 and I need to have tomcat be the static web
server, but I'm not sure how or where to configure
additional virtual directories for a webapp.
I tried adding a Context to the
Howdy,
I tried adding a Context to the
webappBase\WEB-INF\web.xml file:
A context IS a web application: it's a one to one relationship.
But it doesn't seem to work. Can someone please point
me in the right direction to serve static content /
files?
You don't need to configure tomcat to
OK that makes sense and I've tested it and you're
right.
I have a directory structure like this (everything
over SSL):
.../webapps/theWebApp/
.../webapps/theWebApp/certs
and in the .../webapps/theWebApp/ directory I have a
file called main.html that has a link to
Howdy,
and in the .../webapps/theWebApp/ directory I have a
file called main.html that has a link to
https://servername/theWebApp/certs/CACert.cer
and when I click it it will not allow me to save it or
access it at all. However, if I put a test file in
the /certs directory called hi.html, I can
Hello,
I found my solution for deploying webapps with mod_webapp and serving only
dynamic content directly with apache.
In my case, I wanted the document root level to be dynamic, so mounting my
app into a subdirectory didn´t work for me.
So I wrote:
RewriteEngine On
RewriteRule
Hello Again:
I know I can be kinda annoying, but I really need to know if someone could make
mod_webapp + warp configuration to serve only dynamic content, and apache serve only
the static content.
If not, does anyone know where can I find a reference for mod_webapp? Because it
seems like
,
James Williamson
www.nameonthe.net
UK Tomcat Hosting
- Original Message -
From: Gabriel Maffia [EMAIL PROTECTED]
To: Tomcat Users List Service [EMAIL PROTECTED]
Sent: Tuesday, March 19, 2002 5:07 PM
Subject: Apache serving static content
Hello Again:
I know I can be kinda annoying, but I
mod_webapp already works this way. That's the whole point of using it
with Apache, right?
See http://dcb.sun.com/practices/howtos/tomcat_apache.jsp
Ken
Hello Again:
I know I can be kinda annoying, but I really need to know if someone could
make mod_webapp + warp configuration to serve only
Do you mean, that you don´t need no additional configuration to make this
work?
- Original Message -
From: Ken Anderson [EMAIL PROTECTED]
To: Tomcat Users List [EMAIL PROTECTED]
Sent: Tuesday, April 16, 2002 1:37 PM
Subject: Re: Apache serving static content
mod_webapp already works
]]
Sent: Tuesday, April 16, 2002 11:19 AM
To: Tomcat Users List
Subject: Re: Apache serving static content
Gabriel,
I wrote a quick patch a while ago for mod_webapp that lets you
specify patterns to ignore (i.e. the request never sees Tomcat).
So apply the patch and recompile, and in your
James:
Your patch worked Like a charm!
Thanks a Lot!
Gabriel
- Original Message -
From: James Williamson [EMAIL PROTECTED]
To: Tomcat Users List [EMAIL PROTECTED]
Sent: Tuesday, April 16, 2002 1:18 PM
Subject: Re: Apache serving static content
Gabriel,
I wrote a quick patch
Users List
Subject: Re: Apache serving static content
Gabriel,
I wrote a quick patch a while ago for mod_webapp that lets you
specify patterns to ignore (i.e. the request never sees Tomcat).
So apply the patch and recompile, and in your httpd.conf file use
WebAppIgnore directives
-
From: Ken Anderson [EMAIL PROTECTED]
To: Tomcat Users List [EMAIL PROTECTED]
Sent: Tuesday, April 16, 2002 9:25 PM
Subject: Re: Apache serving static content
What is the advantage of deploying all resources of a webapp inside the
webapp directory? If there is a need for a webappIgnore feature
: Apache serving static content
What is the advantage of deploying all resources of a webapp inside the
webapp directory? If there is a need for a webappIgnore feature, perhaps
this question should be brought to the the dev list?
Ken
Brandon Cruz wrote:
I have the same issue with mod_jk. We
-
From: Ken Anderson [EMAIL PROTECTED]
To: Tomcat Users List [EMAIL PROTECTED]
Sent: Wednesday, April 17, 2002 12:35 AM
Subject: Re: Apache serving static content
As a workaround, you can use an apache alias directive.
Alias /images/ $tomcat_home/webapps/webapp_name/images/
Ken
James
PROTECTED]
To: Tomcat Users List [EMAIL PROTECTED]
Sent: Wednesday, April 17, 2002 12:35 AM
Subject: Re: Apache serving static content
As a workaround, you can use an apache alias directive.
Alias /images/ $tomcat_home/webapps/webapp_name/images/
Ken
James Williamson wrote:
Ken,
I've
34 matches
Mail list logo