Issue with current_page_ item css not changing colour
-
Hi!
I am creating a vertical navigation bar within my page.php file that has a PHP bit to recognise the current page so I can style the list item differently:
<ul id="leftcolumn"> <li<?php if ( is_home() || is_front_page() || is_single() || is_search() || is_archive() ) { echo ' class="current_page_item"'; } ?>><a href="https://oropeza.tk/jrphotography/wp/" title="home">work</a></li><?php wp_list_pages('title_li=&exclude=2') ?> </ul>
The home page is a static page but the idea is that when you are on a page the current menu entry will change colour and size, so far ok with the size but color is not changing: This is the CSS:
#leftcolumn ul {
list-style-type: none;
}/* MENU */
ul#leftcolumn li a:link {font-size:16px;font-weight:100;color: #fff; letter-spacing:1px;}
ul#leftcolumn li a:visited {color: #fff;font-weight:100;font-size:16px;letter-spacing:1px;}
ul#leftcolumn li a:hover {color: #5B82CB;font-weight:100;font-size:16px;letter-spacing:1px;}
ul#leftcolumn li a:active {font-weight:100; color: #5B82CB;font-size:16px;letter-spacing:1px;}#leftcolumn ul li.current_page_item a:link {color: #5B82CB; font-weight:100; font-size:9px;letter-spacing:1px;}
And the test site lives here:
https://oropeza.tk/jrphotography/wp/
Any help will be appreciatted.
Thanks!
- The topic ‘Issue with current_page_ item css not changing colour’ is closed to new replies.