[Seaside] #styleLinkWithUrl:

James Megquier jmegq at post.harvard.edu
Sat Oct 16 18:47:19 CEST 2004

> But still I haven't found a way to use an external *.css File.
> I use the WAStyleLibrary now to store the css styles in it, that's 
> okay for
> me, but I'm still wondering, if it's possible to use .css-Files. ;)

Well, here's the kludgy way I did it.  I should just make a method 
called "cssLinkWithUrl:rel:" or something...

updateRoot: anHtmlRoot
	attr := WAHtmlAttributes new.
	attr at: 'rel' put: 'Stylesheet'.
	attr at: 'href' put: 'http://some.server/css/common.css'.
	attr at: 'type' put: 'text/css'.
	attr at: 'media' put: 'screen'.
	anHtmlRoot add: (WAHtmlElement named: 'link' attributes: attr)

But then I found it easier to use the WAStyleLibrary stuff, so I 
subclassed it and put my CSS in methods of that class, and then 
configured it into the application using the config page.


More information about the Seaside mailing list