tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Morgan, Russel" <Russel.Mor...@disney.com>
Subject Help Linking Static Content In a WebApp before and after (6.0.30.x)
Date Tue, 05 Jun 2012 17:30:20 GMT
Tomcat Users:



Has anyone found a graceful way to handle static content linking that works=  both pre and
post the the following change?

https://issues.apache.org/bugzilla/show_bug.cgi?id=3D50026



We have quite a few customers on earlier versions of Tomcat 6 as well as ne= w customers picking
up later versions that are post this patch.  I am looki= ng for some kind of work around that
works in both generations.



Here is an example of what we are doing as far as static linking in our web= app.



So on older tomcat's (prior to 6.0.30)

http://localhost:8080/cms/default/css/gopublish.css

http://localhost:8080/cms/static/css/gopublish.css

both work to hit items in the root of the webapp so .../cms(as webapp)/css/= gopublish.css



On newer Tomcats: (Aka 6.0.35.1 etc etc) http://localhost:7080/cms/default/css/gopublish.css

http://localhost:7080/cms/static/css/gopublish.css

These (actually both work), but only if you have the appropriate folders cr= eated (static/default)



I can get it to work on either version, but I am looking for a "graceful" w= ay to have it
work on both versions.



I don't see that this problem can be worked around by servlet mapping or fi= lters, since
the core behavior has changed.



Our source (IE what we are calling the above assets from)



<link href=3D"../static/css/gopublish.css" media=3D"all" rel=3D"stylesheet"=  type=3D"text/css"
/> <link href=3D"../static/css/ui.css" media=3D"all" rel=3D"stylesheet" type= =3D"text/css"
/> <script src=3D"../static/js/jquery-1.3.2.min.js"></script>

<script src=3D"../static/js/jquery-ui.js"></script>



Any help or insight would be appreciated.



Thanks

Russel Morgan




Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message