Untested and could do with some error checking but this should give you an idea.
$imageExts = array('jpg', 'jpeg', 'gif');
echo '<ul>';
foreach (glob('/path/to/files/*') as $file) {
printf('<li>%s (', basename($file));
if (in_array(pathinfo($file, PATHINFO_EXTENSION), $imageExts)) {
$size = getimagesize($file);
printf('%dx%d ', $size[0], $size[1]);
}
printf('%sb)</li>', filesize($file));
}
echo '</ul>';