Styling Active navigation button in navigation bar

You might want to highlight or change background color of your button for the active page into different color than other navigation buttons so that your visitors will notice which page they are viewing.

The code is
.current_page_item {background:red;}
If you use category list as your nav, the code will be:

You can paste this example code in your css file, of course play with the attribute to get the style that you want.

Latest update: If you are using Tweny Ten wordpress 3 for the active category menu:

.current-category-ancestor {background:red;}

Share the knowledge
Share on Google+0Tweet about this on TwitterShare on Facebook0Pin on Pinterest0Share on Reddit0Email this to someonePrint this page