
    opendir(CD, "bmp");
   
    @tiffs = grep(!/^\./, readdir(CD));
#    print @tiffs;
    @tiffs = sort(@tiffs);
if (0) {    # Generate images
    foreach $f (@tiffs) { 
	print("$f\n");
	$base = $f;
	$base =~ s/\.bmp//;
	system("bmptoppm bmp/$f | pnmscale -xysize 640 480 | cjpeg -progressive -quality 75 >html/images/M$base.jpg\n");
	system("bmptoppm bmp/$f | cjpeg -progressive -quality 75 >html/images/L$base.jpg\n");
    }
exit 0;
}

    $docname = 'Insignes de la Désalpe de Lignières';
    $keywords = 'insignes desalpe lignieres suisse switzerland';

    	open(OF, ">html/index.html");
	print OF <<"EOD";
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
<html version="-//W3C//DTD HTML 3.2 Final//EN" lang="fr">
<head>
<title>$docname
</title>
<style type="text/css">
    DIV.bodycopy {
        margin-left: 15%;
        margin-right: 10%
    }
</style>
<meta name="description" content="$docname">
<meta name="keywords" content="$keywords">
</head>

<body bgcolor="#FFFFFF">
<table width="100%">
<tr><td width="25%" valign=top>&nbsp;
<td width="50%" align=center><h1>$docname</h1>
<td width="25%" align=right>
&nbsp;
<a href="/"> <img align=middle src="images/up.gif" height=32 width=32 border=0 alt="Home"></a> &nbsp; &nbsp;
$next
</table>
<hr>
<p>
<div class=bodycopy>
<small><em>Cliquez sur les images pour les agrandir.</em></small>
EOD

    foreach $f (@tiffs) { 
    	$base = $f;
	$base =~ s/\.bmp//;
	print("$base\n");
	$s = `djpeg html/images/M$base.jpg | pnmfile`;
    	$s =~ m/\D*(\d+) by (\d+)\s/;
    	$width = $1;
	$height = $2;
	print("$base: $width×$height\n");
	print OF <<"EOD";
<h1>$base</h1>

<a href="images/L$base.jpg" target="DesalpeInsigne"><img src="images/M$base.jpg" width=$width height=$height border=0 alt=""></a>
EOD
    }

	print OF <<"EOD";
<p>
&nbsp;

</div>
</body>
</html>
EOD

    close(OF);
