[Seaside] ZnZincStaticServerAdaptor and debug
tulipe.moutarde at gmail.com
Tue Apr 15 16:06:19 UTC 2014
I quickly put this together:
It will serve stuff placed in the assets directory (which must sit next to
the image). Nothing really fancy but does the job:
ZnSeasideStaticServerAdaptorDelegate subclass: #CCStaticServerDelegate
znRequest url firstPathSegment = 'assets'
znRequest url removeFirstPathSegment. "eats the /assets/"
^self staticDelegate handleRequest: znRequest ]
ifFalse: [ ^self adaptor process: znRequest ]
| assetDirectory |
assetDirectory := (FileLocator imageDirectory / 'assets').
^ ZnStaticFileServerDelegate new
directory: (ZnFileSystemUtils directory: assetDirectory) ;
And the Adaptor:
ZnZincStaticServerAdaptor subclass: #CCZincStaticServerAdaptor
^ CCStaticServerDelegate with: self
On Sun, Apr 13, 2014 at 3:16 PM, Johan Brichau <johan at inceptive.be> wrote:
> To serve static files from a directory during development, there still is
> the Seaside-Filesystem package.
> -> Load the 'Filesystem' group from ConfigurationOfSeaside3
> But I also do intend to replace it with serving static files from Zinc
> directly though. But, in the meantime, it's doing the job.
> On 10 Apr 2014, at 08:39, François Stephany <tulipe.moutarde at gmail.com>
> > Ok. I've got quite a bit of external files, I'll roll my own ;)
> > thanks !
> > _______________________________________________
> > seaside mailing list
> > seaside at lists.squeakfoundation.org
> > http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
> seaside mailing list
> seaside at lists.squeakfoundation.org
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the seaside