Wordpress Themes - WP Forum at BFA
Click here to register or to donate.
Auto self-registration is not available here - far too many spammers. This forum has many, many backlinks and because of that there is an intense desire among spammers to drop their links here.

Wordpress Themes - WP Forum at BFA » WordPress Themes » Atahualpa 3 Wordpress theme » Header configuration & styling »

Current/Active page link won't reflect style


  #1  
Old Nov 22, 2013, 12:38 PM
striped aardvark
 
50 posts · Mar 2010
dundas, ontario, canada
http://specializednde.com/ is the site i'm working on. i've used just standard links (h4) in a widget for the top menu, as the menu needed to be bottom aligned with the logo beside it, and this seemed the easiest solution. i've styled the links as follows, but for some reason the active link will not stay background-coloured. is it being affected in some way by the default widget stylings maybe?


h4 a:link {color:#0065B3; background-color: #FFFFFF; padding: 5px; !important;} /* unvisited link */
h4 a:visited {color:#FFFFFF; background-color: #FFFFFF; padding: 5px; !important;} /* visited link */
h4 a:hover {color:#FFFFFF; background-color: #BECFE1; padding: 5px; !important;} /* hover link */
h4 a:active {color:#FFFFFF; background-color: #BECFE1; padding: 5px; !important;} /* selected link */

or is there some way to use the logo option in atahualpa and still have the regular menu align across from it, as the site currently looks?

many thanks for any input!

joan
  #2  
Old Nov 22, 2013, 01:41 PM
juggledad's Avatar
juggledad
 
23,655 posts · Mar 2009
OSX 10.11.5 WP 4.x Atahualpa(all) Safari, Firefox, Chrome
once you 'click' the link, you are sent to a new page and that link stops being active. what you need to do is target a class assigned to it.

When using the wp custom menus or Atahualpa menus, the menu item you clicked on will get a class of 'current-item' (I think that's the class - you need to use FireBug to look at it or view the page source.) and you can target that in your 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 Nov 24, 2013, 07:47 PM
lmilesw's Avatar
lmilesw
 
10,174 posts · Jul 2009
Central New York State USA
Also "active" in CSS referts to the element when it is clicked on. Once you realease the mouse button the state for the link is no longer active.
__________________
~Larry (CNY Web Designs)
This site should be a membership site since it so full of good stuff.
Please consider donating which gives you access to even more good stuff.

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Highligh parent and child navigation menu when active or current etask Page & Category Menu Bars 5 Oct 28, 2012 12:59 PM
Set a color for an "active" or "current" link in a sidebar widget. artaud Sidebars & Widgets 8 Oct 11, 2011 04:57 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
Style differently the active (just clicked) link in Categories and other widgets ymf Sidebars & Widgets 2 Mar 3, 2010 02:58 PM
Bold active page link title - How? snarunas Sidebars & Widgets 11 Oct 20, 2009 07:56 AM


All times are GMT -6. The time now is 01:35 PM.


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