header("Pragma: no-cache");
header("Cache-Control: no-cache, must-revalidate");
?>
/*
seems to hang here??
mail("dcp3@hps.com","Pix Viewed __ $REMOTE_ADDR",$REMOTE_ADDR." __ ".date("m-d-Y"));
*/
// header ("Content-type: text/html");
// header ("Expires: Wednesday, 15-Oct-97 07:49:01 GMT");
// Expires: Wednesday, 15-Oct-97 07:49:01 GMT
Include("common.php"); /* Define tables etc */
$thedir='/southeast/pix';
$thepix='pix'; // default
$hed1="Photos from the 40th reunion - Friday night";
if ($dir==2) {
$thedir='/southeast/pix2';
$thepix='pix2';
$hed1="Photos from the 40th reunion - Saturday night";
}
if ($dir==3) {
$thedir='/southeast/pix3';
$thepix='pix3';
$hed1="Photos from the 45th reunion - Saturday";
}
if ($dir==4) {
$thedir='/southeast/site/pix4';
$thepix='pix4';
$hed1="Photos from the 50th reunion";
}
$enlargeok=($thepix!='pix4') ? ' Click Photo to Enlarge.' : '' ; /// some have no large
// headings
echo <<
$hed1
$enlargeok Home
EOF;
$rdh=opendir($thedir); // read dir handle
$capa=cap($dir); // captions if any
// turn dir into an array so we can sort the photos (come in random and confusing)
while ($pfile=readdir($rdh)) {
$dira[]=$pfile;
}
sort($dira);
while (list($junk,$pfile)=each($dira)) {
list($fname,$ftype)=explode(".",$pfile); // get filename.filetype
if (strlen($pfile)>4) {
if (is_array($capa)) {
$captxt=" ".$capa[$fname];
}
$enlink=($thepix!='pix4') ? "" : '';
echo <<
$enlink
$captxt
EOF;
}
/*
$size = GetImageSize("$thedir/$bfile");
if ($size[0]>500)
echo "$fname $ftype $bfile $size[0] ";
$cmd = "/usr/lib/ImageMagic/ImageMagick-6.0.8/bin/convert -crop 100x0+0+0% -resize 400 -quality 50 /home/dealpix/p/$bfile /tmp/outbig/$bfile";
exec($cmd);
echo "$cmd";
*/
}
exit;
function cap($dir) {
if ($dir==3) {
$t=<<
|