< < < Click here to go back to the main site
List of available files:
templates/
images/
style/
> gallery.css
> contact.txt
> footer.txt
> header.txt
basecode/
> Gallery.php
> gallerybuilder.php
> GalleryItem.php
> GalleryNavigationData.php
> GallerySection.php
> includer.php
> Photograph.php
> Video.php
pictures/
> gpl.txt
> index.php
> opensource.php
Showing source of: ./basecode/gallerybuilder.php
<?php
/***************************************************************************
* jpbGallery 1.0.0 Copyright (c) 2007 Jean-Philippe Barbeau
* Contact: jp $at> jpbarbeau $dot> com
***************************************************************************
* This file is part of the jpbGallery project.
*
* jpbGallery is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 3 of the License, or
* (at your option) any later version.
*
* jpbGallery is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
-***************************************************************************/
define('PHOTODIR', './pictures/');
function apdir($s)
{
return PHOTODIR . $s;
}
$section = new GallerySection('Chicago: The Windy City');
$photo = new Photograph(apdir('DSC01947.JPG'), 'Chicago I', 'This is not the last time you will hear me say this: Chicago is a great city! From great people to impressive buildings and a nice waterfront, Chi-Town has it all.', 113, 150, 600, 800);
$photo->fNumber = 4.5; $photo->exposure = 250; $photo->ISO = 80; $photo->focalLength = 96;
$section->addItem($photo);
$photo = new Photograph(apdir('DSC01960.JPG'), 'Marina City', 'Chicago\'s "Corn Cob Towers" are actually part of a high-end condominium complex called Marina City. These towers unsurprisingly won the 1965 American Institute of Architects Prize for their originality.', 113, 150, 600, 800);
$photo->fNumber = 5.6; $photo->exposure = 250; $photo->ISO = 80; $photo->focalLength = 60;
$section->addItem($photo);
$photo = new Photograph(apdir('DSC01980.JPG'), 'Chicago II', 'As you may see from this picture, Chicago is home to many great waterfront parks. This one, Grant Park, is more than a mile long and stretches all the way to the downown core from the Shedd Aquarium.');
$photo->fNumber = 5.6; $photo->exposure = 500; $photo->ISO = 80; $photo->focalLength = 42;
//$section->addItem($photo);
$photo = new Photograph(apdir('DSC01986.JPG'), 'Chicago III', 'Unsurprisingly, this picture was taken near the John G. Shedd Aquarium.', 113, 150, 600, 800);
$photo->fNumber = 5.6; $photo->exposure = 250; $photo->ISO = 80; $photo->focalLength = 120;
$section->addItem($photo);
$photo = new Photograph(apdir('DSC01995.JPG'), 'Chicago IV', 'Here is Chicago\'s skyline in its full mid-day glory, as viewed from the Alder Planetarium. You simply cannot beat Chicago for North American architecture.', 200, 103, 800, 411);
$photo->fNumber = 5.6; $photo->exposure = 500; $photo->ISO = 80; $photo->focalLength = 36;
$section->addItem($photo);
$photo = new Photograph(apdir('DSC02010.JPG'), 'John Hancock Center', 'At 100 stories tall, the John Hancock building is Chicago\'s second tallest skyscraper (behind the Sears Tower). A popular observatory is located on the 94th floor.', 113, 150, 600, 800);
$photo->fNumber = 5.6; $photo->exposure = 200; $photo->ISO = 80; $photo->focalLength = 60;
$section->addItem($photo);
$photo = new Photograph(apdir('DSC02029.JPG'), 'Sears Tower', 'Visitors to the John Hancock Observatory can enjoy this breathtaking, eye-to-eye view of the always impressive Sears Tower.', 113, 150, 600, 800);
$photo->fNumber = 5.6; $photo->exposure = 80; $photo->ISO = 80; $photo->focalLength = 96;
$section->addItem($photo);
$photo = new Photograph(apdir('DSC02012.JPG'), 'Chicago V', 'The amazing city of Chicago becomes even more spectacular as the Sun starts to set.', 113, 150, 600, 800);
$photo->fNumber = 5.6; $photo->exposure = 320; $photo->ISO = 80; $photo->focalLength = 42;
$section->addItem($photo);
$gallery->addSection($section);
$section = new GallerySection('San Diego');
$photo = new Photograph(apdir('DSC02078.JPG'), 'Old Town San Diego', 'San Diego\'s Old Town district features a distinct yet pleasing Mexican atmosphere.', 113, 150, 600, 800);
$photo->fNumber = 5.0; $photo->exposure = 800; $photo->ISO = 80; $photo->focalLength = 36;
$section->addItem($photo);
$photo = new Photograph(apdir('DSC02281.JPG'), 'Hotel Del Coronado', 'Thanks to its distinctive style, the Hotel Del Coronado is one of the area\'s best known landmarks. It is located on the West side of the Coronado Peninsula, which is itself just West of downtown San Diego. Coronado is reachable either by boat or by car (toll bridge).', 113, 150, 600, 800);
$photo->fNumber = 5.0; $photo->exposure = 320; $photo->ISO = 80; $photo->focalLength = 36;
$section->addItem($photo);
$photo = new Photograph(apdir('DSC02284.JPG'), 'Coronado Beach', 'The Coronado Beach is getting somewhat less busy late on this Wednesday afternoon as the Sun slowly ends its daily cycle.');
$photo->fNumber = 4.5; $photo->exposure = 400; $photo->ISO = 80; $photo->focalLength = 48;
$section->addItem($photo);
$photo = new Photograph(apdir('DSC02299.JPG'), 'San Diego', 'Most mid-sized cities offer an interesting sight at night time and San Diego is no exception. The bright white light reflected on the right side of the picture originates from the Dodgers Stadium, where the local team is playing against (and losing to) the Colorado Rockies.', 200, 74, 800, 296);
$photo->fNumber = 4.0; $photo->exposure = -5; $photo->ISO = 80; $photo->focalLength = 36;
$section->addItem($photo);
$gallery->addSection($section);
$section = new GallerySection('The San Diego Zoo');
//$photo = new Photograph(apdir('DSC02110.JPG'), 'Flamingoes', 'Visitors to the San Diego Zoo are greeted by the flamingoes enjoying life in their pond.');
//$photo->fNumber = 3.5; $photo->exposure = 1000; $photo->ISO = 80; $photo->focalLength = 312;
//$section->addItem($photo);
$photo = new Photograph(apdir('DSC02114.JPG'), 'Aruba Island Rattler (Crotalus Unicolor)', 'WARNING: Rattlesnakes may be found in this area... (Crotalus unicolor)');
$photo->fNumber = 3.5; $photo->exposure = 13; $photo->ISO = 200; $photo->focalLength = 138;
$section->addItem($photo);
$photo = new Photograph(apdir('DSC02139.JPG'), 'Meerkats', 'Meerkats (or suricates) are very smelly, but turned out to be some of my favourite animals at the Zoo. They are apparently very smart and are able to build and find their way around complex networks of burrows. The two individuals shown here, standing on two feet, are actually on guard watching for predators and will alert the other group members in the event of any danger. The tallest of the two does not seem to mind my presence too much but is still keeping an eye on me...', 113, 150, 600, 800);
$photo->fNumber = 3.5; $photo->exposure = 400; $photo->ISO = 80; $photo->focalLength = 114;
$section->addItem($photo);
$photo = new Photograph(apdir('DSC02158.JPG'), 'Lizard', 'This small, exotic lizard is one fast moving fellow! Taking this picture at the right time proved harder than I thought!');
$photo->fNumber = 4.5; $photo->exposure = 640; $photo->ISO = 80; $photo->focalLength = 432;
$section->addItem($photo);
$photo = new Photograph(apdir('DSC02164.JPG'), 'Galapagos Tortoise', 'Even the Galapagos tortoises are enjoying some rest this afternoon in the typical but scorching San Diego heat.');
$photo->fNumber = 3.5; $photo->exposure = 160; $photo->ISO = 80; $photo->focalLength = 324;
$section->addItem($photo);
$photo = new Photograph(apdir('DSC02186.JPG'), 'Panda Bear', 'One of the Zoo\'s panda bears is seen here enjoying a light bamboo snack... aren\'t these just lovely?');
$photo->fNumber = 3.5; $photo->exposure = 200; $photo->ISO = 200; $photo->focalLength = 132;
$section->addItem($photo);
//$photo = new Photograph(apdir('DSC02233.JPG'), 'Giraffe', 'A long necked giraffe enjoys some rare shade on this scorching hot afternoon. One of the Zoo\'s giraffes had just recently given birth to a new baby (pictured behind).');
//$photo->fNumber = 4.5; $photo->exposure = 160; $photo->ISO = 80; $photo->focalLength = 83;
//$section->addItem($photo);
$photo = new Photograph(apdir('DSC02257.JPG'), 'Zebras', 'Zebra mania at the Zoo.', 102, 150, 542, 800);
$photo->fNumber = 4.5; $photo->exposure = 400; $photo->ISO = 80; $photo->focalLength = 204;
$section->addItem($photo);
$gallery->addSection($section);
$section = new GallerySection('Los Angeles');
$photo = new Photograph(apdir('DSC02336.JPG'), 'Cactus', 'There is no shortage of cacti at The Huntington Library\'s Desert Garden.', 113, 150, 600, 800);
$photo->fNumber = 3.5; $photo->exposure = 640; $photo->ISO = 80; $photo->focalLength = 126;
//$section->addItem($photo);
$photo = new Photograph(apdir('DSC02378.JPG'), 'Ryokan', 'This part of the exhibit at The Huntington Library mimics the appearance and feel of a Japanese ryokan (traditional hotel).', 113, 150, 600, 800);
$photo->fNumber = 4.0; $photo->exposure = 30; $photo->ISO = 200; $photo->focalLength = 60;
//$section->addItem($photo);
$photo = new Photograph(apdir('DSC02545.JPG'), 'Avalon I', 'Catalina Island is located about an hour away from Los Angeles in the Pacific Ocean. It is especially popular among snorkelling fans and couples seeking romance. Seen here is the small but lovely town of Avalon.');
$photo->fNumber = 4.5; $photo->exposure = 400; $photo->ISO = 80; $photo->focalLength = 36;
$section->addItem($photo);
$photo = new Photograph(apdir('DSC02458.JPG'), 'Catalina Island', 'Transportation on Catalina Island is mainly done on foot and with the help of glof carts, with the exception of a limited number of tour buses. Seen here is the view one gets to enjoy while driving from Avalon to Catalina\'s Airport-In-The-Sky, appropriately named after its high elevation (1,600 feet / 485 m).');
$photo->fNumber = 5.6; $photo->exposure = 400; $photo->ISO = 80; $photo->focalLength = 36;
$section->addItem($photo);
$photo = new Photograph(apdir('DSC02553.JPG'), 'Avalon II', 'Visitors to Avalon may enjoy a variety of activities, including sunbathing, canoeing and taking "semi-submersible" boat tours.');
$photo->fNumber = 4.5; $photo->exposure = 500; $photo->ISO = 80; $photo->focalLength = 48;
$section->addItem($photo);
$photo = new Photograph(apdir('DSC02608.JPG'), 'Santa Monica', 'This is another try at last year\'s palm trees and sea picture. Really, how could life get any better than this?', 113, 150, 600, 800);
$photo->fNumber = 5.6; $photo->exposure = 250; $photo->ISO = 80; $photo->focalLength = 36;
$section->addItem($photo);
$photo = new Photograph(apdir('DSC02644.JPG'), 'Low Flying Airplane', 'The Los Angeles area offers incredible opportunities for the airplane enthusiast like myself. More precisely, the area around LAX\'s world famous In-N-Out Burger offers this amazing view of the airplanes passing directly overhead as they land. Seen here is an American Airlines Boeing 757 (with winglets) passing about 150 feet overhead.');
$photo->fNumber = 2.8; $photo->exposure = 40; $photo->ISO = 800; $photo->focalLength = 36;
$section->addItem($photo);
$gallery->addSection($section);
$section = new GallerySection('Las Vegas And The Mojave Desert');
$photo = new Photograph(apdir('DSC02720.JPG'), 'Eiffel Tower I', 'There is no shortage of lights in Las Vegas! The Eiffel Tower and the other "landmarks" in town really come to life once the Sun sets.', 113, 150, 600, 800);
$photo->fNumber = 4.5; $photo->exposure = -0.625; $photo->ISO = 80; $photo->focalLength = 36;
$section->addItem($photo);
$photo = new Photograph(apdir('DSC02769.JPG'), 'Valley Of Fire I', 'Whoever suggested that the Mojave Desert was boring has obviously never been to the Valley Of Fire Park. Here, the reddish colored landscape is a refreshing (not literally) change from more traditional desert scenes.', 200, 113, 800, 450);
$photo->fNumber = 5.6; $photo->exposure = 500; $photo->ISO = 80; $photo->focalLength = 36;
$section->addItem($photo);
$photo = new Photograph(apdir('DSC02778.JPG'), 'Valley Of Fire II', 'The colors seen in the Valley Of Fire Park are truely unique. Unfortunately, the valley will be eaten away by Mother Nature in the distant future.', 113, 150, 600, 800);
$photo->fNumber = 5.6; $photo->exposure = 500; $photo->ISO = 80; $photo->focalLength = 48;
$section->addItem($photo);
$photo = new Photograph(apdir('DSC02824.JPG'), 'Valley Of Fire III', 'There is more to the Valley Of Fire than red rock. Seen here is a pleasing blend of red and beige rock with green stuff on top!');
$photo->fNumber = 5.6; $photo->exposure = 800; $photo->ISO = 80; $photo->focalLength = 36;
$section->addItem($photo);
$photo = new Photograph(apdir('DSC02870.JPG'), 'Caesars Palace', 'Celine Dion\'s departure (as of 2007) from Las Vegas is advertised on the huge Caesars Palace sign.', 113, 150, 600, 800);
$photo->fNumber = 5.0; $photo->exposure = 400; $photo->ISO = 80; $photo->focalLength = 36;
$section->addItem($photo);
$photo = new Photograph(apdir('DSC02899.JPG'), 'Bellagio', 'The Bellagio looks as romantic as ever as its world-known fountains get ready for some late-night action.');
$photo->fNumber = 5.6; $photo->exposure = -1.3; $photo->ISO = 80; $photo->focalLength = 36;
$section->addItem($photo);
$photo = new Photograph(apdir('DSC02938.JPG'), 'Eiffel Tower II', 'This is the night version of the Eiffel Tower picture that I took last year. How can you not love Las Vegas\' light show?', 92, 150, 489, 800);
$photo->fNumber = 3.2; $photo->exposure = 3; $photo->ISO = 80; $photo->focalLength = 48;
$section->addItem($photo);
$photo = new Photograph(apdir('DSC03027.JPG'), 'Rhyolite Ghost Town', 'Rhyolite used to be a thriving gold town in the 1900\'s, but times have changed. Now abandonned, it offers thrilling photo opportunities in the middle of the Mojave Desert. This building, I believe, is the old Cook Bank.');
$photo->fNumber = 5.6; $photo->exposure = 640; $photo->ISO = 80; $photo->focalLength = 60;
$section->addItem($photo);
$photo = new Photograph(apdir('DSC03071.JPG'), 'Death Valley', 'Nothing to show but desolation for miles and miles and miles in the appropriately called Death Valley.');
$photo->fNumber = 5.6; $photo->exposure = 500; $photo->ISO = 80; $photo->focalLength = 36;
$section->addItem($photo);
$photo = new Photograph(apdir('DSC03110.JPG'), 'Badwater', 'If this place looks unbearably hot, that\'s because it is. Badwater is the lowest and absolute hottest point in the Western hemisphere. The forecasted temperatore for the time we were there was of more than 116 F (46.7 C). Our tour guide explicitly told us not to touch the wooden sign or we would hurt ourselves! As a matter of fact, my camera temporarily went dead shortly after taking this picture due to the heat.');
$photo->fNumber = 5.0; $photo->exposure = 500; $photo->ISO = 80; $photo->focalLength = 60; $photo->flashUsed = true;
$section->addItem($photo);
$photo = new Photograph(apdir('DSC03128.JPG'), 'Artist\'s Drive', 'As our tour guide said as our journey through Death Valley was about to end: "These are some of the prettiest mountains you will ever get to see!"');
$photo->fNumber = 4.5; $photo->exposure = 800; $photo->ISO = 80; $photo->focalLength = 36;
$section->addItem($photo);
$gallery->addSection($section);
$section = new GallerySection('Random Stuff');
$photo = new Photograph(apdir('DSC01912.JPG'), 'Clouds I', 'Taken on American Airlines flight 2317 as we are about to cross Lake Michigan on our way to Chicago.', 113, 150, 600, 800);
$photo->fNumber = 5.6; $photo->exposure = 500; $photo->ISO = 80; $photo->focalLength = 36;
$section->addItem($photo);
$photo = new Photograph(apdir('DSC02048.JPG'), 'Clouds II', 'As we were about midway through our trip from Chicago to San Diego on American Airlines 309, we found ourselves flying in the vicinity of high rising cumulonimbus clouds. Fortunately for the white-knuckled flyers on board, our captain requested a slight deviation and we avoided all turbulence.');
$photo->fNumber = 5.6; $photo->exposure = 400; $photo->ISO = 80; $photo->focalLength = 36;
$section->addItem($photo);
$photo = new Photograph(apdir('DSC02656.JPG'), 'Bally\'s room', 'Bally\'s might not be the fanciest resort on the Las Vegas Strip, bit I liked it anyway. Some rooms on the good side of the hotel offer a great view of the Eiffel Tower replica and the fountains at Bellagio.');
$photo->fNumber = 4.0; $photo->exposure = 125; $photo->ISO = 80; $photo->focalLength = 36; $photo->flashUsed = true;
$section->addItem($photo);
$gallery->addSection($section);
/*$section = new GallerySection('Videos');
$photo = new Video(apdir('MOV00716.MPG'), 'Casually driving along California\'s scenic Highway 1 between San Luis Obispo and Big Sur.', 117);
$section->addItem($photo);
$gallery->addSection($section);*/
?>