\n \n"; } echo " \n"; } echo "




Dyke's

  Henry's

  Hull's

"; }*/ ?>



"; break; case 1: if (isset($_GET['sub']) {$sub = $_GET['sub'] . "/";} else {$sub = "";} if (isset($_GET['page'])) {$predir = $_GET['page'] . "/" . $sub; $ppage = $_GET['page'];} else {$predir = "";} $rodir = $predir . "photos/"; $odir = $predir . "thumbs/"; ini_set(memory_limit, "6000M"); if (is_dir($rodir)) { if ($dh = opendir($rodir)) { $arnum = 1; $picture = array(); while (($pic = readdir($dh)) !== false) { $count++; if ($pic != "." && $pic != "..") { if(!file_exists($odir . "thumb_" . $pic)) { $filename = $pic; list($width, $height) = getimagesize($rodir . $filename); if ($width < $height) { $newheight = "120"; $newwidth = $width * $newheight / $height; } else { $newwidth = "120"; $newheight = $height * $newwidth / $width; } $thumb = imagecreatetruecolor($newwidth, $newheight); $source = imagecreatefromjpeg($rodir . $filename); imagecopyresized($thumb, $source, 0, 0, 0, 0, $newwidth, $newheight, $width, $height); imagejpeg($thumb, $odir . "thumb_" . $pic); } else $picture[] = $pic; } } closedir($dh); } else echo "#2 Fail"; } else echo "#1 Fail"; $start = (isset($_GET['start']) ? $_GET['start'] : 0); $end = $start+30; $thumbcounter = -1; $arrow = count($picture); foreach($picture as $num=>$picfinal) { if($num < $start || $num >= $end) continue; $thumbcounter++; $pic = str_replace(" ", "%20", $picfinal); $picbg = $odir . "thumb_" . $pic; $picbgexplode = explode(".", $picbg); $jpgs = array("J", "P", "G", "E", "e"); $jpgsrep = array("j", "p", "g", "", ""); $picbgexplode = str_replace($jpgs, $jpgsrep, $picbgexplode); if($picbgexplode[1] != "jpg") {$picbg = "http://www.billandcarols.com/img/notjpg.gif";} if ($thumbcounter == 6) { $thumbcounter = 0; echo "
"; if($start >= 1) { $start = $start - 30; echo ""; $start = $start + 30;} if($count > 30 && $start+30 < $count) { $start = $start + 30; echo ""; } echo "
"; break; case 2: if (isset($_GET['imgurl'])) {$imgurl = $_GET['imgurl']; list($width, $height) = getimagesize($imgurl); if ($width < $height) { if ($height > "540") {$newheight = "540"; $newwidth = $width * $newheight / $height;} } else { if ($width > "540") {$newwidth = "540"; $newheight = $height * $newwidth / $width;} } echo "
"; } echo " "; break; } ?>