Sidebar page and category
-
Hello everyone,
This is my first post.
I can’t seem to find a resolution to my problem.
In my side bar I have this code:
<?php if (in_category('pageone') || is_page('pageone')) { ?>
HTML menu
<?php } elseif (in_category('pagetwo') || is_page('pagetwo')) { ?>
HTML alternative menu
<?php } else { ?>
HTML error message
<?php } ?>The menu appears on a post but defers to the first if statement on a page. I can’t figure out what I am doing wrong.
Can anyone help?
Thanx in advance.
Viewing 5 replies - 1 through 5 (of 5 total)
Viewing 5 replies - 1 through 5 (of 5 total)
- The topic ‘Sidebar page and category’ is closed to new replies.