Thumbnail Gallery added to example site

This post was written 4 years ago.
Sun, 04 Nov 2012
To add a thumbnail gallery to a blog post, create a folder win the images folder with the same name as the blog post. By default this will give you thumbnails linking through to a larger version of the image. These can be used with lightbox, or similar plugin.

eatStatic Image Cache working

This post was written 5 years ago.
Sun, 29 Apr 2012
As eatStatic was set up as a travel blog, I wanted a convenient way to include photos in blog posts at a sensible size (e.g. 600 pixels wide), without having to manually resize images uploaded from my camera. Also I wanted to be able to upload images which were already at the right size, without having to upload them via any kind of image library. Any image uploaded to a subfolder (e.g. "misc/sunset.jpg") of your data/images folder can be included in a post by referencing it as e.g. /images/misc/filename_600.jpg.

This uses PHP GD module to create a resized version of the image on demand and copy it to a corresponding subfolder in your images folder, including creating a subdirectory if necessary. This means that subsequent requests for the image are served up directly as a static file (delete it if you change the original and want it re-cached).

There is no special image tag available - use a standard HTML image tag to include an image in a post e.g:-

<img src="/images/misc/sunset_600.jpg" alt="sunset" />

sunset

There is also a gallery system available which will render a set of thumbnails for each image found in a sub folder named the same as the blog post - i'll document that seperately in another post.
This post was written 5 years ago, which in internet time is really, really old. This means that what is written above, and the links contained within, may now be obsolete, inaccurate or wildly out of context, so please bear that in mind :)

Demo site online!

This post was written 5 years ago.
Sat, 28 Apr 2012
The eatStatic demo site is now running as an unmodified clone of the master branch of the github repo. To install (full instructions to follow):-

  1. Download or clone the code
  2. Take a look at eatStatic_config.php - in particular you will need to change the host name, used to detect whether the site is in production or development mode
  3. Make sure the "data" folder is writable, then run /scripts/setup.php to check and create the cache folders

This post was written 5 years ago, which in internet time is really, really old. This means that what is written above, and the links contained within, may now be obsolete, inaccurate or wildly out of context, so please bear that in mind :)