<div id="mason"> <?php if ($zpmas_ss && $_zp_page == 1) { ?> <div id="cycle" class="box <?php echo $zpmas_col_ss; ?> album"> <?php if ($zpmas_sscount > $_zp_gallery->getNumImages(2)) { $zpmas_sscount = $_zp_gallery->getNumImages(2); } ?> <?php if ($zpmas_albumorimage == 'image') { printImageStatistic($zpmas_sscount, $zpmas_functionoption, '', true, false, false, 40, '', $zpmas_ss_size_w, $zpmas_ss_size_h, true); } else { if ($zpmas_albumorimage == 'album') { if ($zpmas_sscount > $_zp_gallery->getNumAlbums(false, true)) { $zpmas_sscount = $_zp_gallery->getNumAlbums(false, true); } printAlbumStatistic($zpmas_sscount, $zpmas_functionoption, true, false, false, 40, '', $zpmas_ss_size_w, $zpmas_ss_size_h, true); } else { ?> <ul> <?php $randomList = ""; for ($i = 1; $i <= $zpmas_sscount; $i++) { $randomImage = getRandomImages(); if (is_object($randomImage) && $randomImage->exists) { $imageName = $randomImage->getTitle();
if ($zpskel_strip == 'random') { echo '<h3>' . gettext('Random Images') . '</h3>'; } else { echo '<h3>' . gettext('Latest Images') . '</h3>'; } ?> </div> <?php if ($zpskel_strip == 'latest') { ?> <div<?php echo $classfull; ?> > <?php printImageStatistic(8, 'latest', '', false, false, false, 40, '', 190, 190, true, false); ?> </div> <?php } else { ?> <div<?php echo $classfull; ?> > <?php printRandomImages(8, 'random-image', 'all', '', 190, 190, true); ?> </div> <?php }
$zpmin_albumorimage = 'image'; $zpmin_functionoption = 'mostrated'; break; case "image-toprated": $zpmin_albumorimage = 'image'; $zpmin_functionoption = 'toprated'; break; case "random-daily": $zpmin_albumorimage = ''; $zpmin_functionoption = 'daily'; break; } ?> <?php if ($zpmin_albumorimage == 'image') { printImageStatistic(1, $zpmin_functionoption, '', true, true, false, 40, '', 535, 535, false); } else { if ($zpmin_albumorimage == 'album') { printAlbumStatistic(1, $zpmin_functionoption, true, true, false, 40, '', 535, 535, false); } else { $randomImage = getRandomImages($zpmin_functionoption); if (is_object($randomImage) && $randomImage->exists) { $randomImageURL = html_encode($randomImage->getLink()); echo '<a href="' . $randomImageURL . '" title="' . sprintf(gettext('View image: %s'), html_encode($randomImage->getTitle())) . '">'; $html = "<img src=\"" . html_encode($randomImage->getCustomImage(535, NULL, NULL, NULL, NULL, NULL, NULL, TRUE)) . "\" alt=\"" . html_encode($randomImage->getTitle()) . "\" />\n"; echo zp_apply_filter('custom_image_html', $html, false); echo "</a>"; echo '<h3><a href="' . $randomImageURL . '" title="' . sprintf(gettext('View image: %s'), html_encode($randomImage->getTitle())) . '">' . html_encode($randomImage->getTitle()) . '</a></h3>'; echo "<p>" . zpFormattedDate(getOption('date_format'), strtotime($randomImage->getDateTime())) . "</p>"; } else { echo gettext('No Images Exist...');
/** * Prints the latest images by mtime order (date uploaded order) * * @param string $number the number of images to get * @param string $albumfolder folder of an specific album * @param bool $showtitle if the image title should be shown * @param bool $showdate if the image date should be shown * @param bool $showdesc if the image description should be shown * @param integer $desclength the length of the description to be shown * @param string $showstatistic * "hitcounter" for showing the hitcounter (views), * "rating" for rating, * "rating+hitcounter" for both. * @param integer $width the width/cropwidth of the thumb if crop=true else $width is longest size. (Default 85px) * @param integer $height the height/cropheight of the thumb if crop=true else not used. (Default 85px) * @param bool $crop 'true' (default) if the thumb should be cropped, 'false' if not * @param bool $collection only if $albumfolder is set: true if you want to get statistics from this album and all of its subalbums * @param bool $fullimagelink 'false' (default) for the image page link , 'true' for the unprotected full image link (to use Colorbox for example) */ function printLatestImagesByMtime($number = 5, $albumfolder = '', $showtitle = false, $showdate = false, $showdesc = false, $desclength = 40, $showstatistic = '', $width = NULL, $height = NULL, $crop = NULL, $collection = false, $fullimagelink = false) { printImageStatistic($number, "latest-mtime", $albumfolder, $showtitle, $showdate, $showdesc, $desclength, $showstatistic, $width, $height, $crop, $collection, $fullimagelink); }
/** * Prints the latest images by mtime order (date uploaded order) * * @param string $number the number of images to get * @param string $albumfolder folder of an specific album * @param bool $showtitle if the image title should be shown * @param bool $showdate if the image date should be shown * @param bool $showdesc if the image description should be shown * @param integer $desclength the length of the description to be shown * @param string $showstatistic "hitcounter" for showing the hitcounter (views), * "rating" for rating, * "rating+hitcounter" for both. * @param integer $width the width/cropwidth of the thumb if crop=true else $width is longest size. (Default 85px) * @param integer $height the height/cropheight of the thumb if crop=true else not used. (Default 85px) * @param bool $crop 'true' (default) if the thumb should be cropped, 'false' if not * @param bool $collection only if $albumfolder is set: true if you want to get statistics from this album and all of its subalbums */ function printLatestImagesByMtime($number = 5, $albumfolder = '', $showtitle = false, $showdate = false, $showdesc = false, $desclength = 40, $showstatistic = '', $width = 85, $height = 85, $crop = true, $collection = false) { printImageStatistic($number, "latest-date", $albumfolder, $showtitle, $showdate, $showdesc, $desclength, $showstatistic, $width, $height, $crop, $collection); }