ZenphotoCMS Forum
Skipping album.php - 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: Skipping album.php (/thread-63.html)



Skipping album.php - RogerUsh - 2005-09-30

Is there a way to skip the album page?

I want the user to be able to click on the album icon in the gallery page and go directly to the first image of that album. Is this possible?

I looked at the template-functions but I can't figure out how to pull out the [img][/img] and `values seperately within thenext_albumandnext_image` loops respectively.

Any suggestions?

Thanks!




Skipping album.php - trisweb - 2005-09-30

It's possible, sure...

In index.php, you'll have something like...

`while (next_album()):

 next_image();

 [[ code from album.php to display image thumbnail and link goes here ]]

 while(next_image()) { } // A hack to skip the rest of the images....

endwhile;`

You can basically put the functions on whatever page you want, they really don't care.

the while(next_image()) { } is unfortunately necessary for now because I haven't planned for the situation where you'd only do a partial loop... I might add some better way in the future, but that should work for now.




Skipping album.php - RogerUsh - 2005-09-30

You did it again, I put this code in my index.php:


">
``


``
``

Worked like a charm, you are really ontop of this stuff. I've used Wordpress and Folderblog, and this has been by far the easiest application to use and the best support I've seen. 

Thanks!



Skipping album.php - trisweb - 2005-10-01

Your gallery looks wonderful Roger - I love the thumbnail stuff you've done. I'd love to get a generalized theme based on that idea, hint hint ;-)




Skipping album.php - nocabt - 2008-03-05

Hi, I tried this method and got this error:

[b]Call to a member function getSubalbums() on a non-object in /home/thomas/public_html/jfiege/photography/zp-core/template-functions.php on line 298[/b]

Ideas?




Skipping album.php - nocabt - 2008-03-05

I just checked a comment I left about this at another post-
http://www.zenphoto.org/support/topic.php?id=752&replies=10

That method worked great. Should have checked that before posting here....