See http://www.frankma.nl/test/zomp381
This Zomplog runs on PHP 4.
I made 3 categories, 3 posts, 2 pages.
Go to the homepage - everything's allright.
Click on cat 1 (menutab), cat 2 or cat3: the tab lights up and the right posts are shown. (I changed the color of the "current" tab to yellow, for easy spotting of the bug).
The same goes for tabs page 1 and page 2 (don't mind the "= xxx" in the tab for now).
Now, click on post 3 in the sidebar (latest entries) - looks OK, eh?
Click on post 2 in the sidebar - hey ho! What's that? Menutab 2 lightens up[[BR]]
Click on post 1 in the sidebar and menutab page 1 lightens up.
They both say "= detail" in the menutab. I modified the displayPagesList-function to show the value of $content.
But, when $content = detail, why does the page-tab lighten up?
I tried to solve it by modifying displayPagesList-function:
I changed the line
if($_GET[id] == $page[id]){
to
if(($_GET[id] == $page[id]) and ($content = page)){
but the result was even stranger. When I then clicked on post 2 the menutabs said "page 1 = detail" and "page 2 = page".
But when I clicked post 1 they both changed to "= page".
I reset my testversion to the original, with menutabs being highlighted in yellow, and display of the value of $detail in the page tabs, so you can easily see it.
I removed the modification " and ($content = page)" in displayPagesList-function.
So far, I don't know where the bug is situated...
½ hour later, after a short nap: solved!
Should have been ($content == page), not ($content = page).
This solved it.
I'll put it in the trunk