open (PHOTOS,"photos.dat"); while () { chop; ($photoId,$photoDescription) = split (": ",$_); $photoDesc{$photoId}=$photoDescription; } foreach $file (@ARGV) { $f = $file; $f =~ s/\.\w+$//; print "\n"; print "
\n"; print "\n"; print "
\n"; print ""; print "$photoDesc{$f}"; print "
\n"; print "\n"; open (HTML,">$f.shtml"); print HTML "\"$f\"\n"; close (HTML); }