On Thursday, January 5, 2012 1:24:21 PM UTC-8, Thomi wrote: > > Hi, > > I'm working on a pylons project, and we have users trying to host the > web-app under a non-root path (i.e. host it at '/myapp/' rather than at > '/'). We've been pretty good about using 'h.url_for' to generate links in > our jinja2 templates, so most things work as expected. However, our CSS > file has paths to icons, background images etc. Since these are served as > static files these paths never get modified. > > I'm sure this is a problem lots of people come across - can anyone suggest > a solution? I can think of two possibilities: > > 1) Remove all paths from the css files, and put them in the jinja2 > templates instead - this seems really ugly, and I'd rather not do this. > 2) Somehow serve the css file as a jinja2 template. It'd be nice if there > was some way to say ' all requests for a .css file should render the > requested file with jinja2 and return the result.' > > Any ideas? > > Can you just make the paths in your stylesheets relative?
-- You received this message because you are subscribed to the Google Groups "pylons-discuss" group. To view this discussion on the web visit https://groups.google.com/d/msg/pylons-discuss/-/qFf9X_LAqG4J. To post to this group, send email to pylons-discuss@googlegroups.com. To unsubscribe from this group, send email to pylons-discuss+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/pylons-discuss?hl=en.