I love this kind of stuff. Here’s a simple command line script that will output xHTML gallery of images in a single directory. Requires ImageMagick and zsh.

for i in sponsor-logos/*.*;do
j=`identify -format "width=\"%[fx:w]\" height=\"%[fx:h]\"" $i`
echo \<div\>\<img src=\"$i\" $j alt=\"$i:t\" /\>\<\/div\>
done

Sure I could have done this in php/rails/whatever, but I needed something quick and valid and output that I later use for the jquery “cycle” plugin (which I love, you can see it in use here, look for the cycling logos on the middle right of the page) and this does the trick.

There’s a dearth of documentation on  the jquery cycle plugin; sounds like a blog post.

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

Performance Optimization WordPress Plugins by W3 EDGE