![]() |
|
Next/Previous Album links - 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: Next/Previous Album links (/thread-1288.html) |
Next/Previous Album links - badcircle - 2007-03-15 I have my next and previous album links working correctly, but as it is now, once you reach the first or the last album, the respective link just goes to the index. Is there a way to hide the Previous Album link on the first album and the Next Album link on the last album? Next/Previous Album links - badcircle - 2007-03-15 I noticed that the image.php has this handy feature: ` " title="Previous Image">« prev " title="Next Image">next »` tried replacing the word Next/Previous Album links - thinkdreams - 2007-03-16 @badcircle- Providing your using the latest code for Zenphoto, you should be able to use functions which are pretty new and documented here: http://www.zenphoto.org/trac/wiki/DeveloperReference#getNextAlbumURLandgetPrevAlbumURL They are part of the core code. Now, as far as the hasPrevImage() thing, I don't think there are comparable functions that exist that do that same thing, at least not from what I can see. That's probably an easy change to make though. Try: `function hasNextAlbum() { global $_zp_current_album; return $_zp_current_album->getNextAlbum(); } function hasPrevAlbum() { global $_zp_current_album; return $_zp_current_album->getPrevAlbum(); }` I haven't had a chance to test it yet, but maybe Tris will have a sec to run over it briefly. Next/Previous Album links - badcircle - 2007-03-18 amazing thinkdreams -- works like a charm |