Wordpress Themes - WP Forum at BFA
There will be no more development for Atahualpa (or any other theme), and no support. Also no new registrations. I turned off the donation system. I may turn the forum to read only if it gets abused for spam. Unfortunately I have no time for the forum or the themes. Thanks a lot to the people who helped in all these years, especially Larry and of course: Paul. Take care and stay healthy -- Flynn, Atahualpa developer, Sep 2021

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

Different background on active menu tab on home


  #1  
Old Dec 9, 2012, 02:52 AM
Harald
 
72 posts · Mar 2010
Different background on active menu tab on home

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
 
23,765 posts · Mar 2009
OSX 10.11.5 WP 4.x Atahualpa(all) Safari, Firefox, Chrome
add some CSS after that CSS prefixed with 'body.home' and undo the settings in that original CSS
__________________
"Tell me and I forget, teach me and I may remember, involve me and I learn." - Benjamin Franklin
Juggledad | Forum Moderator/Support
  #3  
Old Dec 9, 2012, 05:26 AM
Harald
 
72 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
 
23,765 posts · Mar 2009
OSX 10.11.5 WP 4.x Atahualpa(all) Safari, Firefox, Chrome
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
__________________
"Tell me and I forget, teach me and I may remember, involve me and I learn." - Benjamin Franklin
Juggledad | Forum Moderator/Support
  #5  
Old Dec 9, 2012, 07:50 AM
Harald
 
72 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
 
23,765 posts · Mar 2009
OSX 10.11.5 WP 4.x Atahualpa(all) Safari, Firefox, Chrome
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.
__________________
"Tell me and I forget, teach me and I may remember, involve me and I learn." - Benjamin Franklin
Juggledad | Forum Moderator/Support

Bookmarks

Tags
menu tab



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 11:27 AM.


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