+ // FIXME: we consider thumbnail are correctly sized if gd library is
+ // installed. That may not always be true. For example if gd was installed
+ // after images were initially uploaded.
+ if (function_exists ("imagecreatefromjpeg")) {
+ if ($feature->imgpath) {
+ $imgurl = image_url_from_imgpath ($feature->imgpath);
+ $thumburl = thumb_url_from_imgpath ($feature->imgpath);
+ $contentHTML .= sprintf ('<a href="%s"><img alt="%s" src="%s"></a>', $imgurl, $alt, $thumburl);
+ }
+ }
+