Warning: 2015-10-19: Major upgrade in progress. Site somewhat functional, with bugs...

My version of PHPgraphy

For my photo galleries on the web, I decided to use the very nice http://phpgraphy.sourceforge.net/ phpgraphy system, as it is simple, fast, reliable, and scalable (along with http://www.sgal.org/forum/ singapore and http://jalbum.net/ jalbum). It has all that I was needing from a "photo gallery" system, except that it didnt provide a way for readers to download a whole album easily in one zip file. I thus quickly added this functionality to phpgraphy, adapted to my needs:
  • linux-only (it forks a shell script)
  • with only french & english texts

phpgraphy-screenshot.png

If you want to use it, you can:

Implementation details

  • a new link download the whole album is added to the links at the top righ. This link text is the string $txt['download_album'] that I provided in engish and french but could be added for the other languages
  • this calls a shell script, cgi/zipdir that will create a zip file (with the zip command that must exist on the system) with no compression of all the .jpg and .jpeg files at the top level of the album (does not recurse in sub dirs) that the browser will download. The zip file be cached after the download. This script only works on unix, to do thinks properly for the official phpgraphy release would means recoding it in php.
    • You may want to clean old cache files by a crontab entry like:
      00 06 * * * find _your-phpgraphy-dir_/tmp -type f -mtime +30 -exec rm {} \;
      the above removing cached zips older than 30 days
  • I also added som BR tags after A links in the links at the top right for a better layout
  • and replaced some space by non-breaking spaces in English & French texts for a better layout

-- ColasNahaboo - 2008-08-16

History

  • 2008-08-18 caches the zip files
  • 2008-08-16 first version, was generating the zip files on the fly each time

Comments

Please leave comments on the http://sourceforge.net/forum/forum.php?thread_id=2170139&forum_id=18798 thread for this addon on the phpgraphy help forum.

Topic attachments
I Attachment Action Size Date Who Comment
phpgraphy-colas-v2.patchpatch phpgraphy-colas-v2.patch manage 7 K 18 Aug 2008 - 23:25 ColasNahaboo patch v2, corresponding to the changeset 3 10c4c760ac76 Aug 19 01:21:57 2008
phpgraphy-screenshot.pngpng phpgraphy-screenshot.png manage 132 K 16 Aug 2008 - 15:56 ColasNahaboo  
Topic revision: r18 - 18 Aug 2008, ColasNahaboo
This site is powered by FoswikiCopyright © by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding Colas? Send feedback