44 lines · 1.3 KB · Text
RawDownload
SMAK is another image gallery app for werc.(by JGL.yiyus 2009) It displays thumbnails of the image files in thedirectory if no index file is found, and showspreviews of the images in synthetic urls of theform path/img for the file path/img.jpg. Thepreview preloads the next image, so it can bestored on the client cache. To enable SMAK, add: 	conf_enable_smak to _werc/config in the dir with the image gallery. Comments can be added to the preview image withmarkdown syntax through the file path/_img.md forthe file path/img.jpg. To configure SMAK to your taste, set these variables:    - smak_extensions=(png jpg jpeg bmp gif)   - smak_prev_width=420   - smak_thumb_height=96 For further customizations, use the tpl files. Youcan copy the files preview.tpl and/or thumbnails.tplto _werc/smak/ for a given gallery, or use lib filesper site or directory in _werc/lib/smak/. SMAK uses the p9p tools to convert the images: bmp,jpg, png and gif to read input files; resample andtopng to transform and write them. The _werc directory has to be writable by theweb server. Thumbnails and preview png files willbe stored in _werc/smak/thumb and _werc/smak/prev.Be sure that your web server is serving the staticfiles or images won't be correctly cached by the client. FAQ:- What is the meaning of SMAK?  http://www.smak.be/