//Page components answer 'yes' or 'no'
$page_name = 'boystoys';
$lock = 'yes';
$breakout = 'yes';
$refresh = 'no';
$path = './';
//Page Title Start
$page_title = '
';
//Page Title End
//Page Header Funtion
function title() {}
// Header Include Statment Start-->
require_once($path . 'header.php');
// Header Include Statment End -->
?>
error_reporting(E_ALL ^ E_NOTICE);
require_once("photo/integratedtemplate.inc.php" ); // get this from pear.php.net or cvs.php.net
require_once("photo/autogallery.inc.php" ); // get this from circle.ch/scripts
// define to create the images index automatically or
// reading it from an index-file
define("GALLERY_SOURCE", "file");
if(GALLERY_SOURCE == "file" )
{
/**
* define galleries from file; always start with an index of 1!
*/
$arr = file("photo/index.album");
function trim_array ($value, $key) {
global $arr, $multiple;
$i = 0;
foreach ($arr as $key => $val) {
// prevent adding empty lines to the selection menu
if(strlen(trim($val)))
$multiple[++$i] = explode("#", $val);
}
}
array_walk(&$arr, 'trim_array');
} else
{
/**
* read image-folders of the format "YYYY-MM-DD". this is
* pretty cool if you upload images with forms and let generate
* php a folder on each "upload-day"
*/
$d = dir("./" );
while($entry=$d->read() ) {
if(stristr($entry, strftime("%Y") )) {
if(is_dir($entry)) $multiple[++$index] = array("./cache", "./$entry", "./templates/frame.png", $entry );
}
}
}
// handle query-manipulations
if(!isset($_GET['g'])) $_GET['g']=1;
// get instance of autogallery
$ag = &new autogallery($multiple[$_GET['g']][0], $multiple[$_GET['g']][1], $multiple[$_GET['g']][2] );
$ag->desc = "Page(s): ";
// handle the template file
$tpl = &new IntegratedTemplate("photo/templates" );
$tpl->loadTemplatefile("tpl.index.php", true, true);
$content = array(
// set rows and columns of images per page
"htm_content" => $ag->thumbnail_table(6,4, $multiple ),
// get the hosts address
"htm_host" => "http://" . $_SERVER['HTTP_HOST'] . (strlen($_SERVER['PHP_SELF'] ) ? "" . str_replace(basename($_SERVER['PHP_SELF']), "", $_SERVER['PHP_SELF']) : "" ),
// set a title for the pop-up window
"htm_script" => $ag->show_jscript("NOSS Photo Gallery"),
);
$tpl->setVariable($content);
$tpl->show();
?>
// ad routine //
// Size = 728 or 460
$size = 728;
include ($path . "ads/ad_code.php")
// end ad routine //
?>
require_once($path . 'footer.php'); ?>