Hello Thiago!

Your proposal was (again) the good solution, so thanks a lot :o)

Here follows the code :

    @SetupRender
    void setup(){
        Asset asset = assetSource.getContextAsset("static/css/form.css",
null);
        renderSupport.addStylesheetLink(asset,null);
        ...
    }

Which is rendered in HTML as :

<link href="/assets/ctx/76f6e908f48d0e66/static/css/form.css"
rel="stylesheet" type="text/css">

Have a nice day!

Thomas.

2010/2/24 Thiago H. de Paula Figueiredo <thiag...@gmail.com>

> On Wed, 24 Feb 2010 10:18:18 -0300, Thomas Cucchietti <
> thomas.cucchie...@gmail.com> wrote:
>
>  Alexander,
>>
>> this was the first thing I tried to do :
>>
>> @SetupRender
>>    void setup(){
>>        renderSupport.addStylesheetLink("context:static/css/form.css",
>> null);
>>        ....
>>    }
>>
>
> @Inject AssertSource and use one of its methods to get an Asset pointing to
> your file. Then add it using RenderSupport.addStylesheetLink(Asset asset).
>
> --
> Thiago H. de Paula Figueiredo
> Independent Java, Apache Tapestry 5 and Hibernate consultant, developer,
> and instructor
> Owner, software architect and developer, Ars Machina Tecnologia da
> Informação Ltda.
> http://www.arsmachina.com.br
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
> For additional commands, e-mail: users-h...@tapestry.apache.org
>
>

Reply via email to