Print list of ALL albums

Hi.

I'm trying to print a list of all present albums on my zenphoto install (index page and album pages). I want this to be in
    in my sidebar at all times.
    I've tried using <?php getAllAlbums( "" ); ?> but it prints nothing when having added to album.php. According to the documentation this also just prints "a list of all albums decendent from an album". I want all albums listed (not only sub albums from the current album).

    Thank you.

Comments

  • acrylian Administrator, Developer
    I've tried using <?php getAllAlbums( "" ); ?> but it prints nothing when having added to album.php. According to the documentation this also just prints "a list of all albums decendent from an album". I want all albums listed (not only sub albums from the current album).
    You should read correctly. The documentation say it "returns". If it would print it would be called printAllAlbums(). Anyway, this is not what you need as it is "dependent from an album".

    What you need is the print_album_menu plugin which the Zenpage theme for example uses by default in its sidebar.
  • Thank you for your reply!

    print_album_menu seems to work fine. I'm wondering if there's a preferred way for creating expanding/collapsing menus of subalbums?

    I'm looking at menu_manager, but Usage information ( http://www.zenphoto.org/documentation/plugins/zp-extensions--menu_manager.php.html ) seems to be missing.
  • acrylian Administrator, Developer
    I am not sure I understand waht you mean with expanding and collapsing. The menu can be set to show only the subalbums of the current album. See the documentation. You mean a JS toggle menu? The menus are all standard html list so you would have add specific JS functionality yourself. You might even need to create your own menu function, depending on what you need and the script used requires.

    The menu manager works basically the same as the album menu, with a few differences in the html generate (see the source code). The menu manager links is somehow wrong but you should really be able to find it on the function documention yourself. http://www.zenphoto.org/documentation/plugins/_zp-extensions---menu_manager.php.html
Sign In or Register to comment.