[Seaside] static image files

Esteban A. Maringolo emaringolo at gmail.com
Wed Feb 8 12:57:36 CET 2006


2006/2/8, Michel Bany <m.bany at wanadoo.fr>:
> In the projects I am participating in, I always recommend having static
> images
> stored as Smalltalk source code in methods that return a byte array
>
>     html
>         imageWithDocument: (ImageLibrary perform: imageName asSymbol)
>         mimeType: 'image/jpeg'
>         fileName: imageName, '.jpg'.
>
> This produces a large Smalltalk image, but makes versioning and
> configuration
> a lot easier, since the application and the images are guaranteed to be
> in synch.

This is true, but "how much large" images are we talking about?
If it's about small pictures such as icons, buttons, and similar ones
is acceptable, but if you have a photogallery, or many many pictures
is questionable.

In the case of Commanche I can't tell, but in the case of Swazoo based
implementations, other alternative (_additionaly_ to the one you
mention) is to have a FileResource, and a couple of methods in html
builder to reference such files.

Best regards,

--
Esteban A. Maringolo
eMaringolo at gmail.com


More information about the Seaside mailing list