Wordpress Themes - WP Forum at BFA
Click Here To DONATE! Support the theme development, get more attention and additional benefits based on your donation level. Your forum name will be highlighted.

Wordpress Themes - WP Forum at BFA » WordPress Themes » Atahualpa 3 Wordpress theme » Page & Category Menu Bars »

Different background on active menu tab on home


Build custom WP THEMES, without
coding.
Click here for THEMEFRAME

From the author of Atahualpa, the #1 most
downloaded (700,000+) theme @ wordpress.org
  #1  
Old Dec 9, 2012, 02:52 AM
Harald
 
70 posts · Mar 2010
I use this code to highlight current page in the menu bar, but would like to exclude the home page. How do I do that?

/* ================================================ */
/* how to highlight current page */
/* ================================================ */
ul.rMenu li.current_page_item a:active,
ul.rMenu li.current_page_item a:visited,
ul.rMenu li.current_page_item {
color: #ffffff !important;
background: #34597F !important;
}
  #2  
Old Dec 9, 2012, 05:05 AM
juggledad's Avatar
juggledad
 
21,959 posts · Mar 2009
OSX 10.8.5 WP 3.8.x Atahualpa 3.7.x Safari 6.x Firefox 25 XP
add some CSS after that CSS prefixed with 'body.home' and undo the settings in that original CSS
__________________
If you like my help, please consider donating. I am happy to provide greater detail on this and other topics if you hire me. Please send detailed support requests to me as a private message, thank you.
Juggledad | Forum Moderator/Support
  #3  
Old Dec 9, 2012, 05:26 AM
Harald
 
70 posts · Mar 2010
Hi juggledad,
I am sorry, but I don't understand what you want me to do. Just to make sure, I want the background to change on current page on all pages except home page. When I am on home page, I want the background to be the same as on the menu bar.
Thanks,
Harald
  #4  
Old Dec 9, 2012, 07:08 AM
juggledad's Avatar
juggledad
 
21,959 posts · Mar 2009
OSX 10.8.5 WP 3.8.x Atahualpa 3.7.x Safari 6.x Firefox 25 XP
You will add the same CSS selectors with the prefix and the rules will be set to what you have for the non-active pages
__________________
If you like my help, please consider donating. I am happy to provide greater detail on this and other topics if you hire me. Please send detailed support requests to me as a private message, thank you.
Juggledad | Forum Moderator/Support
  #5  
Old Dec 9, 2012, 07:50 AM
Harald
 
70 posts · Mar 2010
This is the code I have. The new code is "not to highlight home page". This did not work. The home page gets the same background as the other tabs.

/* ================================================ */
/* how to highlight parent of current page */
/* ================================================ */
ul.rMenu li.current_page_ancestor a:active,
ul.rMenu li.current_page_ancestor a:visited,
ul.rMenu li.current_page_ancestor {
margin-top:0px;
color: #ffffff !important;
background: #34597F !important;
}
/* ================================================ */
/* how to not highlight home page */
/* ================================================ */
ul.rMenu li.current_page_item_20 a:active,
ul.rMenu li.current_page_item_20 a:visited,
ul.rMenu li.current_page_item_20 {
color: #ffffff !important;
background: transparent!important;
}
/* ================================================ */
/* how to highlight current page */
/* ================================================ */
ul.rMenu li.current_page_item a:active,
ul.rMenu li.current_page_item a:visited,
ul.rMenu li.current_page_item {
color: #ffffff !important;
background: #34597F !important;
/*background: -webkit-gradient(linear, 0 0, 0 bottom, from(#748daf), to(#5b6e88))!important;
background: -webkit-linear-gradient(#748daf, #5b6e88)!important;
background: -moz-linear-gradient(#748daf, #5b6e88)!important;
background: -ms-linear-gradient(#748daf, #5b6e88)!important;*/
/*background: -o-linear-gradient(#748daf, #5b6e88)!important;*/
/*background: linear-gradient(#748daf, #5b6e88)!important;*/
/*-ms-filter:"progid:DXImageTransform.Microsoft.linear-gradient(startColorstr=#748daf,endColorstr=#5b6e88 )"!important;*/
/*filterrogid:DXImageTransform.Microsoft.linear-/*gradient(startColorstr=#748daf,endColorstr=#5b6e8 8)!important;*/
/*-webkit-border-radius: 4px !important;*/
/*-moz-border-radius: 4px !important;*/
/*border-radius: 4px !important;*/
/*-ms-filter:"progid:DXImageTransform.Microsoft.Blur(pix elRadius=4)" !important;*/
/*filterrogid:DXImageTransform.Microsoft.Blur(pix elRadius=4) !important;*/

The site is www.blueberrybuilders.com
  #6  
Old Dec 9, 2012, 08:25 AM
juggledad's Avatar
juggledad
 
21,959 posts · Mar 2009
OSX 10.8.5 WP 3.8.x Atahualpa 3.7.x Safari 6.x Firefox 25 XP
As I originally said, you need to start the CSS selector with 'body.home blah blah' for that selector to only apply on the home page.
__________________
If you like my help, please consider donating. I am happy to provide greater detail on this and other topics if you hire me. Please send detailed support requests to me as a private message, thank you.
Juggledad | Forum Moderator/Support

Bookmarks

Tags
menu tab

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
How to change "Background Color: Parent" when a menu item is active floralprints Page & Category Menu Bars 3 Aug 19, 2012 05:50 AM
Background color of home-box i Menu 1 proveref Page & Category Menu Bars 1 Jul 2, 2012 05:30 AM
[SOLVED] active menu > how to keep active a link in menu page? bender57 Page & Category Menu Bars 1 Apr 28, 2010 07:44 AM
Active page menu background image css help dixieprosser Page & Category Menu Bars 1 Mar 18, 2010 01:13 PM
Background Color Active Links Zen Nomad Page & Category Menu Bars 0 Nov 15, 2009 08:53 AM


All times are GMT -6. The time now is 10:26 AM.


Powered by vBulletin® Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.