wicket-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Fran├žois-Xavier Lacroix <fxlacr...@gmail.com>
Subject Re: Autolinking resources in 1.4: different path after second request
Date Fri, 02 Oct 2009 16:31:43 GMT
i think one thing is better with header...
you can add css or javascript from every action you deal with...
Wicket manage all the added and make all the needed tags

+

On Fri, Oct 2, 2009 at 3:17 PM, Daniel Stoch <daniel.stoch@gmail.com> wrote:

> I don't think there is something wrong in using <wicket:link> to add
> resources (this way has some advantages too).
> But I have tried your proposition and instead <wicket:link> in html, I
> have added it in HomePage constructor:
> add(CSSPackageResource.getHeaderContribution(HomePage.class, "main.css"));
>
> Now the link is always rendered as (correctly for me :)):
> <link rel="stylesheet" type="text/css"
> href="resources/com.mycompany.HomePage/main.css" />
>
> Well I think both ways (using <wicket:link> or header contribution in
> code) should works the same.
>
> --
> Daniel
>
> 2009/10/2 Fran├žois-Xavier Lacroix <fxlacroix@gmail.com>:
> > I m not sure this is the best way to add css ressources...
> > try to use instead
> > add(CssPackageResource.getHeaderContribution("main.css"));
> > assuming your css file is in you webapp
> >
>

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