I'm new to Zenphoto and playing with the default theme. Now I've set the album display to 8 albums per page, but I get the album navigation everywhere, even when only using 2 albums. The page navigation turns to normal when I the album itself with the pictures.
Anyone who recognizes this? It's not a fault in my theming, because I switched to a default theme for testing, but got the same problem.
I'm sorry I wasn't so clear . Here you can see a testpage. Only one album in this album, but the page/album navigation is present (album navigation is set to 8 albums per page). Also, clicking on 'next' results in a page with the images of that album and not the next (not existing) album.
Hope this helps...
Damn... the pagenavigation returned and I don't know why...
Yesterday it was present so I thought it would be a cache problem. But now it's still there...
I'm using this function: printPageListWithNav.
I discovered a few things:
To be able to check out the 'wrong' navigation, I've set the display back to 12 albums per page and 12 images per page...
Yes, I did refresh the database. And no, I can't find any hidden files, except for that one .htaccess file in the root folder of the ZP-installation, but that looks normal to me. I also checked all folders inside the main folder for hidden files...
The only thing I could try is to purge the cache again, but I don't thinks that will help...
Found it!!! Sigh...
Removing
$firstPageImages = normalizeColumns('2', '6');
from
``
in the head of the album.php (no matter what theme) and the album page navigation is working again as it should. So I wonder if this is a bug or not, because it happened in each and every theme I tested and caused my album navigation to go wrong, sometimes displaying navigation for three albumpages where there was only one (so clicking to page two or three resulted in empty pages).
Perhaps someone else can test it. In my case it went wrong with albums that contained more than six subalbums.
Well, in viewing your site what I see is a gallery with apparently 7 albums in it. The first six are displayed on page 1 and the 7th on page 2. That would tend to indicate that the albums per page was set to 6.
The one thing you should look at is the function normalizeColumns(). Many times problems with mis-matches of pagination stem from not using this function correctly.
[i]That would tend to indicate that the albums per page was set to 6.[/i]
Yes, I just set it to 6 to test the pages after I removed that line, so what you see now is ok. But before that it was set to 20 or 500 and even then the page navigation for the albums was present.
If you want I can put the line back for you to see what happened?
About that function... Because it was present in all the themes I assumed it was a necessary line of code for the gallery to work, to 'switch' to a few albums less or more, just to make it flow nicely on the screen, but I guess I was wrong. Never thought about removing it.
Perhaps it went wrong because I don't use 'transition' pages?
OK, thanks. Perhaps, even if I was the first who had this 'problem', it is a good idea to put this in the theming tutorial. There is a very small section that refers to this piece of code and that it is used for transitional pages, but it does not say that it is to be used only(!) when using transitional pages, and that it would be better otherwise to remove it.
Perhaps (and just thinking from a users perspective) it would be an idea to let the code check IF albums AND images or both present on that page, and only then actually applying/running it. This way that piece of code can stay in the head of all the pages, no matter how someone wants to fill his/her gallery .
Like I said, in my case the problem is solved and I know what to do now, but I'm just thinking of new users...