You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by Martin Makundi <ma...@koodaripalvelut.com> on 2010/04/18 20:16:30 UTC
Wicket Branding with setStyle - question about static images in
src/webapp/*
Hi!
I am trying to brand my app with session.setStyle. My question is
about static images in src/webapp/*
I have been using them like <img src="/images/logo.png"/>
Do I have to switch them into <img src="/images/logo.png"
wicket:id="image-tag"/> and attach a corresponding Image component?
Seems like a lot of work and it will not work properly with images
referred in css files.
Couldn't I just parametrize WicketServlet somehow to serve styled
images and fallback on default when styled image is not available?
Anybody done this before, care to drop few example lines of code?
**
Martin
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org
Re: Wicket Branding with setStyle - question about static images in
src/webapp/*
Posted by Igor Vaynberg <ig...@gmail.com>.
see ContextImage, create your own version that is style-aware.
alternatively you can create tag handlers just like wicket:link that
will add your own version of ContextImage for you.
-igor
On Sun, Apr 18, 2010 at 11:16 AM, Martin Makundi
<ma...@koodaripalvelut.com> wrote:
> Hi!
>
> I am trying to brand my app with session.setStyle. My question is
> about static images in src/webapp/*
>
> I have been using them like <img src="/images/logo.png"/>
>
> Do I have to switch them into <img src="/images/logo.png"
> wicket:id="image-tag"/> and attach a corresponding Image component?
>
> Seems like a lot of work and it will not work properly with images
> referred in css files.
>
> Couldn't I just parametrize WicketServlet somehow to serve styled
> images and fallback on default when styled image is not available?
>
> Anybody done this before, care to drop few example lines of code?
>
> **
> Martin
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org