How to display only links without thumbnails within an album

Is there a way to insert just links to subalbums without thumbnails? I'd like the user to be able to click on a "Plant Families" album thumbnail and see an alphabetical list of the dynamic subalbums (plant families) instead of multiple pages of thumbnails. This is not a parent album so I can't assign a different theme to that album. I've tried using codeblocks on the album using the printAlbumMenuList but that works only if subalbum are not hidden.

I can link to a page of plant families in the codeblock, but then the list would not be dynamic.

Is there any simple way of accomplishing this?

Comments

  • fretzl Administrator, Developer
    In album.php look at what is between the next_album() loop.

    `
    <?php while (next_album()): ?>
    [output]
    <?php endwhile; ?>
    `
    This is the part that prints your album titles:
    `" title="<?php echo gettext('View album:'); ?> <?php echo getAnnotatedAlbumTitle();?>"><?php printAlbumTitle(); ?>`

    You can remove the rest if you want.

    Of course you'll have some styling to do.

    More info on the next_album() function can be found here:
    http://www.zenphoto.org/documentation/functions/_template-functions.php.html#functionnext_album
  • I understand that part, but I need this change to occur only on ONE album, not all of them. Would I insert an if album = xyz here? I don't know php that well, so can you give me an example of what and where to put that?

    Thanks.
  • acrylian Administrator, Developer
    ìf($_zp_current_album->name == '<album name to get>')) { ... } else {... } ` where the album name to get must included the parents if it is a subalbum (for example the name for "album2" within "album1" is "album1/album2")
  • Here's what I have so far but nothing is changing since I'm assuming I'm not doing the current album correctly. Album path is /test/flora. Have tried /test/flora; /flora and flora

    '
    <?php if (isAlbumPage()) { ?>
    <div id="album-wrap" class="clearfix">

      <?php $x=1; while (next_album(true)): $lastcol="";
      if ($x==3) {$lastcol=" class='lastcol'"; $x=0;} ?>
      <li<?php echo $lastcol; ?>>

      <?php if ($_zp_current_album->name == 'flora')
      { ?>
      " title="<?php echo gettext('View album:'); ?>
      <?php echo getBareAlbumTitle();?>"><?php printCustomAlbumThumbImage(getBareAlbumTitle(),NULL,89,64,89,64); ?>
      <h4>" title="<?php echo gettext('View album:'); ?> <?php echo getBareAlbumTitle();?>"><?php printAlbumTitle(); ?></h4>

      <?php } else { ?>
      " title="<?php echo gettext('View album:'); ?>
      <?php echo getBareAlbumTitle();?>"><?php printCustomAlbumThumbImage(getBareAlbumTitle(),NULL,267,192,267,194); ?>
      <h4>" title="<?php echo gettext('View album:'); ?> <?php echo getBareAlbumTitle();?>"><?php printAlbumTitle(); ?></h4>

      <?php } ?>
      '
  • acrylian Administrator, Developer
    Your code is messed up. Please use backticks or the standard html tag for code.

    From what I see you always include a custom album thumbs so you always get an image...

    You also did apparently not read what I said abou album names. if your ZP install is in "test" then that is of course not part of the album name.. if "test" is the toplevel parent then the album name would be `test/flora`.
Sign In or Register to comment.