Hello!
I'm currently doing some front-end development for a website I've been working on and I've run into a small issue: I need to apply an opacity to the background of an anchor without applying that opacity to the text inside the anchor.
(it's the buttons in the upper right that say "Services, About, etc"
Below is what the navigation is supposed to look like:
http://go.prevue.it/view/bzbq3
And this is what it currently looks like:
http://methodistphysiciansclinic.com/index.cfm?event=clinic/192-dodge
My HTML:
Code:
<ul class="nav" id="subnav">
<li class="services">
<a href="#">Services</a>
</li>
<li class="about">
<a href="#">About</a>
</li>
</ul>
(which is actually generated through ColdFusion)
Code:
<ul class="nav" id="subnav">
<cfoutput>#event.printNavList(skipLevels=1)#</cfoutput>
</ul>
My CSS:
Code:
#subnav{
text-align:right;
height:33px;
float:right;
padding:10px 0;
}
ul#subnav.nav li{
display:block;
float:left;
margin:10px 0 0 10px;
}
ul#subnav.nav li:last-child{
margin-right:21px;
}
/* doing it this way causes the text to also become transparent
ul#subnav.nav li.about a{
color:#ffffff;
} */
ul#subnav.nav li a{
opacity:.5;
padding:12px 9px;
background:#fff;
border-radius:3px;
-webkit-border-radius:3px;
-moz-border-radius:3px;
}
any help would be greatly appreciated! Thanks!