I'm looking at the example and I'm not exactly sure I understand what is going on. So you have your main Page, and then you seem to be including a ListView component whose model consists of the CSS filename.


I don't understand what HeaderContributor is all about (I can't find it in the Javadoc or CVS), nor do I understand how this mechanism causes Wicket to map the CSS filename to a globally-stable URL. Perhaps you could shed some more light on this?

Also is there a way to associate a CSS markup with a Page in a direct fashion? Or must I really use a ListModel/View?

Thanks,
Gili

Eelco Hillenius wrote:
See the wiki: http://wicket.sourceforge.net/wiki/doku.php?id=user:include_css_references_for_components for one way to do this.

And if you *really* need to include dynamic CSS, take a look at how the guys from DWR (http://eireneh.thorubio.org/dwr/) do it. Basically, the include *.js files in their generated pages, but then at the server side, they interpred the js request, and generated the contents on the fly. You could do the same with Wicket, by using resources. In fact, I think Johan is playing with this right now for his - private - AJAX experiments.

Eelco

Gili wrote:


I tried using class Label to construct the CSS statement dynamically, but Label escapes HTML reserved characters so that method does not work...


Eelco, how are you handling this problem...?



------------------------------------------------------- SF email is sponsored by - The IT Product Guide Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now. http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click _______________________________________________ Wicket-develop mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/wicket-develop




-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
_______________________________________________
Wicket-develop mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/wicket-develop

Reply via email to