#!/bin/bash

#rm HEADER.html
touch HEADER.html

for image in 2*.png; do
    i=${image%%.png}
    echo $image
    convert -size 300x300 -resize 300x300 $image _thumb${i}.jpg
    echo "<a href=\"${i}.png\" target=\"new\"><img src=\"_thumb${i}.jpg\"></a>" >> HEADER.html
done

