Welcome to Geeklog, Anonymous Wednesday, December 04 2024 @ 01:53 pm EST
Geeklog Forums
looking for block
Anonymous
Anonymous
I am looking for a block that lets coppermine pictures to be show within randomly?
Can anyone help?
6
3
Quote
Status: offline
JohnVanVliet
Forum User
Full Member
Registered: 10/09/03
Posts: 161
i have'nt tried this but it MIGHT??? work
you can edit block-random.php for Gallery
line 117 to 130 will nead to be edited
global $cache;
global $gallery;
$cache = array();
$everybody = $gallery->userDB->getEverybody();
$albumDB = new AlbumDB();
foreach ($albumDB->albumList as $tmpAlbum) {
if ($everybody->canReadAlbum($tmpAlbum)) {
$seeHidden = $everybody->canWriteToAlbum($tmpAlbum);
$numPhotos = $tmpAlbum->numPhotos($seeHidden);
$name = $tmpAlbum->fields["name"];
if ($numPhotos > 0) {
$cache[$name] = $numPhotos;
and i do not know what the new code should be
this is only a guess seeing as i use gallery
i hope it helps
you can edit block-random.php for Gallery
line 117 to 130 will nead to be edited
Text Formatted Code
function scanAlbums() {global $cache;
global $gallery;
$cache = array();
$everybody = $gallery->userDB->getEverybody();
$albumDB = new AlbumDB();
foreach ($albumDB->albumList as $tmpAlbum) {
if ($everybody->canReadAlbum($tmpAlbum)) {
$seeHidden = $everybody->canWriteToAlbum($tmpAlbum);
$numPhotos = $tmpAlbum->numPhotos($seeHidden);
$name = $tmpAlbum->fields["name"];
if ($numPhotos > 0) {
$cache[$name] = $numPhotos;
and i do not know what the new code should be
this is only a guess seeing as i use gallery
i hope it helps
4
4
Quote
All times are EST. The time is now 01:53 pm.
- Normal Topic
- Sticky Topic
- Locked Topic
- New Post
- Sticky Topic W/ New Post
- Locked Topic W/ New Post
- View Anonymous Posts
- Able to post
- Filtered HTML Allowed
- Censored Content