2008/5/6 Adam Hardy <[EMAIL PROTECTED]>:
> So if I made a taglib that stored the CSS in its body into the request
> attribute, e.g. requestScope.specialCss, a bit like this:
>
> <adam:style var="specialCss">
> #ContextBody div.repo span { width: 25px; }
> </adam:style>
>
> then I could achieve this? Or do you mean that it's not possible?
It's not possible to put it in the body and hope that it will be
processed in the header, simply because the header gets renderer
before the body, and when you render the body it's too late to process
the header.
I think that your option is to do some pre-rendering processing, for
example using a ViewPreparer, to store the extra CSS items, and then
use them when rendering the <head>.
Antonio