Member
Member
vincent3569   2017-10-09, 06:40
#1
hi

some template functions exist to know if an album page have subalbums or images (`isAlbumPage()` and `is ImagePage()`). the response depends of the current page displaying the album. ok

but is there a function to know if this album is with subalbums or is only with images, not depending of the current page I am on ?

thanks in advance for your help.
Member
Member
vincent3569   2017-10-09, 06:48
#2
sorry for disturbing, I found my response:
there is two functions in album class for that (`getNumAlbums()` and `getNumImages()`)
Administrator
Administrator
acrylian   2017-10-09, 08:11
#3
And you always can do similar things using the object model directly without any page context given you have an album object like `$_zp_current_album->getNumAlbums()`. The global variable `$_zp_current_album` is of course only set in related page context.
Member
Member
vincent3569   2017-10-09, 08:58
#4
of course, you're right.
I am in album context, so the functions above are working well for my needs.
  
Powered By MyBB, © 2002-2026 MyBB Group.
Made with by Curves UI.