₦airaland Forum

Welcome, Guest: Register • Login • With Google • Trending • Recent • New

Stats: 3,344,404 members, 8,511,681 topics. Date: Monday, 02 November 2026 at 07:51 AM

Toggle theme

Please help me with this Code? - Programming - Nairaland

Nairaland Forum › Science/Technology › Programming › Please help me with this Code? (866 Views)

1 Reply

Please help me with this Code? by feelme3(op): 7:27pm On Jan 10, 2010
Please, am trying out my little knowledge on css. Please, how do I make the active links to remain the same color with the hover? I don't seem to get it here. Am almost giving up on this but am eager to learn more. Please help.


.mattblacktabs{
width: 100%;
overflow: hidden;
border-bottom: 2px solid black; /*bottom horizontal line that runs beneath tabs*/
}

.mattblacktabs ul{
margin: 0;
padding: 0;
padding-left: 0px; /*offset of tabs relative to browser left edge*/
font: bold 10px Verdana, Arial, Helvetica, sans-serif;
list-style-type: none;
}

.mattblacktabs li{
display: inline;
margin: 0;
}

.mattblacktabs li a{
float: left;
display: block;
text-decoration: none;
margin: 0;
padding: 5px 15px; /*padding inside each tab*/
border-right: 1px solid white; /*right divider between tabs*/
color: #000040;
background: #ccc; /*background of tabs (default state)*/
}

.mattblacktabs li a:hover, .mattblacktabs li.selected a{
color: #fff;
background: #000040; /*background of tabs for hover state, plus tab with "selected" class assigned to its LI */
}
Re: Please help me with this Code? by yawatide(f): 9:47pm On Jan 10, 2010
This has already been answered here: https://www.nairaland.com/nigeria/topic-379196.0.html

Programming mod: feel free to lock this thread.
1 Reply

5,000 Naira For Someone Who Can Reverse This Code • Is Something Wrong With This Code • Need Help With This Code • 2 • 3 • 4

Do You Want To Learn Video Editing? • Why Is This Not Working For Me • China, Japan Or India - Which Is Best?