![]() |
|
getNumImages subalbums - Printable Version +- ZenphotoCMS Forum (https://forum.zenphoto.org) +-- Forum: Support (https://forum.zenphoto.org/forum-1.html) +--- Forum: General support (https://forum.zenphoto.org/forum-4.html) +--- Thread: getNumImages subalbums (/thread-1999.html) |
getNumImages subalbums - freindler - 2007-12-29 Hi all, Thx, getNumImages subalbums - sbillard - 2007-12-29 You would have to recursively sum all subalbum numImages. something like this should work: global $_zp_gallery; $sum = $album->getNumImages(); $subalbums = $album->getSubalbums(0); while (count($subalbums) > 0) {
} return $sum; }` Caveat: I have not tried this. getNumImages subalbums - timo - 2007-12-30 This does indeed work, although it is slightly different than the getNumImages subalbums - freindler - 2007-12-30 thanks a lot, getNumImages subalbums - sbillard - 2007-12-30 Will do, thanks for testing it out. |