Ready to get started?Download WordPress


Menu item highlight for posts (3 posts)

  1. paul448
    Posted 1 year ago #

    Hi Folks

    I am trying to work out how to do the following:

    My Blog page on my website displays all of my posts. and at the top of the page I have a menu where the 'Blog' anchor is highlighted to indicate that the page is 'active'.

    What I am trying to achieve is that when you click on a post the anchor for 'blog' still shows. At the moment it doesn't when you click on the single page(posts).

    In my header.php file I have the following:

    				 <?php wp_nav_menu (array('menu'=>'custom_menu'));?>

    If anyone can help it would be greatly appreciated.

    Thanks in advance

  2. Andrew
    Forum Moderator
    Posted 1 year ago #

    So the anchor for 'blog' currently disappears when you click on the single page?

  3. paul448
    Posted 1 year ago #

    I want the anchor for 'blog' to remain highlighted when the user clicks on posts on the blog page.

    At the moment the anchor in the menu for 'blog' is only highlighted when the page is active, what i want is when you click on a post page the 'blog' anchor is still highlighted

    I not sure is their is some sort of cod that can do this or if I am not doing something in the wordpress admin?

Topic Closed

This topic has been closed to new replies.

About this Topic