/*** * CONFIG ***/ $_CONFIG['gallery_dir'] = 'galleries/'; $_CONFIG['pictures_dir'] = 'pictures/'; $_CONFIG['babes_dir'] = 'babes/'; $_CONFIG['pornstars_dir'] = 'pornstars/'; $_CONFIG['models_dir'] = 'models/'; $_CONFIG['timestamp_file'] = '/date_added.txt'; // always with a leadings lash $_CONFIG['pics_file'] = '/pics.txt'; // always with a leadings lash /*** * OPTIONS ***/ //-- LATEST GALLERIES $_CONFIG['latest_count'] = 9; //number of gals $_CONFIG['latest_cols'] = 3; //cols per row $_CONFIG['latest_width'] = "95%"; //table width /*** * VARIABLES ***/ $_CONFIG['latest_update'] = NULL; /*** * FUNCTIONS ***/ ### LOAD GALLERIES # function load_galleries () { // prepare global $_CONFIG; global $_GALLERIES; global $_TIMESTAMPS; $x=1; $_dir = opendir($_CONFIG['gallery_dir']); while (FALSE !== ($gallery = readdir($_dir))) { if (strstr($gallery, '-')) { $_path = explode('-',$gallery); $_TIMESTAMPS[getTimestamp($_CONFIG['gallery_dir'].$gallery.$_CONFIG['timestamp_file'])."-$x"] = $gallery; $_GALLERIES[$gallery]['model'] = str_replace('_', ' ', $_path[0]); $_GALLERIES[$gallery]['set_title'] = str_replace('_', ' ', $_path[1]); $_GALLERIES[$gallery]['path'] = $_CONFIG['gallery_dir'] . $gallery; $_GALLERIES[$gallery]['pics'] = file_get_contents($_CONFIG['gallery_dir'].$gallery.$_CONFIG['pics_file']); $_GALLERIES[$gallery]['thumbnail'] = "view_picture.php?src=" . $gallery . "-" . $_GALLERIES[$gallery]['pics'] . ".jpg&height=220"; } $x++; } closedir($_dir); // sort krsort($_TIMESTAMPS); } load_galleries(); ### GET TIMESTAMP # function getTimestamp($path) { global $_CONFIG; if (file_exists($path)) { $_timestamp = file_get_contents($path); } else { $_timestamp = createTimestamp($path); } if ($_timestamp > $_CONFIG['latest_update']) { $_CONFIG['latest_update'] = $_timestamp; } return $_timestamp; } ### CREATE TIMESTAMP # function createTimestamp($path) { $_timestamp = @mktime(); file_put_contents($path,$_timestamp); return $_timestamp; } /*** * DISPLAY FUNCTIONS ***/ ### LATEST UPDATE # function DIS_Latest_Update() { global $_CONFIG; return @date('M dS, Y', $_CONFIG['latest_update']); } ### LATEST GALLERIES # function DIS_Latest_Galleries($count="", $cols="") { // configure global $_page; global $_CONFIG; global $_TIMESTAMPS; global $_GALLERIES; if (empty($count)) { $count = $_CONFIG['latest_count']; } if (empty($cols)) { $cols = $_CONFIG['latest_cols']; } $start = ($_page['page'] * $_CONFIG['latest_count']) - $_CONFIG['latest_count']; $end = $start + $_CONFIG['latest_count']; // construct $_html = "\n
| \n
\n
\n " . $_GALLERIES[$gallery]['model'] . "\n " . $_date . " New: " . $_GALLERIES[$gallery]['set_title'] . ", " . $_GALLERIES[$gallery]['pics'] . " pics. \n | \n
";
if ($y==$cols&&$x!==$count) { $_html .= "\n
if ($_page['page']>1) : ?>Page =$_page['page']; ?> of endif; ?>Pornstars, Babes and Models FREE from www.DigiDolls.com!
Updated =$latest_update; ?>

Full DigiDoll Galleries if ($_page['nextpage']) : ?> , Page =$_page['nextpage']; ?> of Free Pornstars > endif; ?>