[Catalyst] process stand alone css file with TT?

Kyle Godbold kgodbold at adpro-ads.com
Thu Jul 24 21:11:26 BST 2008

Is there any way to use Template Toolkit to render a stand alone
css page that can be linked in with <link rel="stylesheet"> ? I've
tried rendering it through its own function and it will render the
css but the output isn't recognized and used by any page when its linked.
I'm not sure if its the header thats sent or the fact that it has no .css
extention in the filename when its downloaded.

sub style :Local {
    my ( $self, $c ) = @_;
    $c->stash->{template} = "style.css"; }

Keeping it out of the header will cut my page sizes almost in half and using
css like this will make my current project much easier but so far I have
found no working way to do it and keep it in it's own file.

#ars_logo a:hover {   
 position: relitive;
 display: block;
 background: #FFF url([% c.uri_for('/static/images/ars-logo-tall.png') 
%]) no-repeat scroll 0px -150px; }

More information about the Catalyst mailing list