if($index-1 >= 0) {?>
[ prev ]
} ?>
|
//--- This is where the large pictures are resized so that they maintain ratio---
$sizeee = getimagesize ("$imagelist[$index]");
$imgwidth = $sizeee[0];
$imgheight = $sizeee[1];
if ($scale == 1 || $imgwidth > $maxwidth || $imgheight > $maxheight) { // decide if img needs to be scaled
$newwidth = $imgwidth/($imgheight/$maxheight);
$newheight = $imgheight/($imgwidth/$maxwidth);
if ($imgwidth < $imgheight) {
if ($newwidth > $maxwidth)
{
?>
} else {
?>
}
} else {
if ($newhight > $maxheight)
{
?>
} else {
?>
}
}
} else { ?>
}
?>
|
if($index+1 < count($imagelist) ) {?>
[ next ]
} ?>
|