Hi,
Can anyone tell me how using CSS I can get my navigation bar link to stay highlighted (white)?
I have read quite a few posts but I’m still unclear how to implement them for a dynamic site.
I am a complete novice so any help would be much appreciated!
I am using Joomla 1.5 CMS and here is the complete CSS code:
h1, h2, h3, h4, h5, h6 { font-family: Arial, Helvetica, sans-serif; }
h1 {
font-weight: lighter;
color: #3C4C5A;
}
#page h1 a {
color: #3C4C5A;
text-decoration: none;
}
h2 { color: #497496; }
h3 { color: #3C4C5A; }
h4 { color: #497496; }
h5 { color: #3C4C5A; }
h6 { color: #497496; }
h1 { font-size: 16px; line-height: 26px; }
h2 { font-size: 22px; line-height: 22px; }
h5 { font-size: 9.5px; font-weight:bold; line-height:15px; }
#left h1, #left h2, #left h3, #left h4, #left h5, #left h6 { color: #dcdcdc; }
#right h1, #right h2, #right h3, #right h4, #right h5, #right h6 { color: #dcdcdc; }
/*
* anchor
*/
a:link { color: #000000; }
a:visited { color: #000000; }
a:hover { color: #B34437; }
a:current {color:#FFFFFF;}
.sidebar a:link,
.sidebar a:visited { color: #98908a; text-decoration: none;}
.sidebar a:visited {line-height:100%;}
.sidebar a:hover { color: #ffffff; }
.sidebar a:hover {line-height:100%; }
.sidebar li#current
{
color: #FFFFFF;
font-weight: bold;
}
a.icon-folder {
padding-left: 17px;
background: url(../images/typography/icon_folder.png) 0 40% no-repeat;
}
a.icon-file {
padding-left: 17px;
background: url(../images/typography/icon_file.png) 0 40% no-repeat;
}
a.icon-download {
padding-left: 17px;
background: url(../images/typography/icon_download.png) 0 40% no-repeat;
}
a.icon-external {
padding-left: 17px;
background: url(../images/typography/icon_external.png) 0 40% no-repeat;
}
a.icon-pdf {
padding-left: 17px;
background: url(../images/pdf_button.png) 0 40% no-repeat;
}
/*
* emphasis
*/
em.box {
padding: 0px 3px 0px 3px;
border: 1px dotted #aaaaaa;
background: #f5f6f7;
font-family: "Courier New", Courier, monospace;
font-style: normal;
white-space: nowrap;
}
#left em.box,
#right em.box,
#bottom em.box {
background: #232328;
border: 1px dotted #3C3C50;
}
/*
* unsorted lists
*/
/* icon style */
ul.arrow,
ul.checkbox,
ul.check,
ul.star {
margin: 10px 0px 10px 0px;
padding-left: 20px;
list-style: none;
}
ul.arrow li,
ul.checkbox li,
ul.check li,
ul.star li {
margin: 5px 0px 5px 0px;
padding-left: 35px;
font-weight: bold;
line-height: 26px;
}
ul.arrow li { background: url(../images/typography/list_arrow.png) 0 0 no-repeat; }
ul.checkbox li { background: url(../images/typography/list_checkbox.png) 0 0 no-repeat; }
ul.check li { background: url(../images/typography/list_check.png) 0 0 no-repeat; }
ul.star li { background: url(../images/typography/list_star.png) 0 0 no-repeat; }
/* links style */
ul.links {
margin: 10px 0px 20px 0px;
padding-left: 0px;
list-style: none;
}
ul.links li {
padding-left: 15px;
height: 25px;
line-height: 25px;
background: url(../images/typography/list_links.png) 0px 0 no-repeat;
cursor: pointer;
}
ul.links li:hover { background-position: 0px -35px; }
#page ul.links li a { text-decoration: none; }
/* table style */
ul.table {
margin: 20px 0px 20px 0px;
padding-left: 0px;
list-style: none;
}
ul.table li {
padding: 5px;
border-bottom: 1px solid #c8c8c8;
}
ul.table li:nth-child(odd) { background: #f0f0f0; }
ul.table li:nth-child(even) { background: #ffffff; }
ul.table li:last-child { border: none; }
/*
* ordered lists
*/
ol.disc {
margin: 10px 0px 10px 0px;
padding: 0px 0px 0px 45px;
background: url(../images/typography/list_disc.png) 20px 0px repeat-y;
}
ol.disc li {
margin: 5px 0px 5px 0px;
padding-left: 10px;
font-weight: bold;
line-height: 26px;
}
/*
* horizontal rule
*/
hr.dotted {
margin: 15px 0px 15px 0px;
display: block;
background: url(../images/typography/line_dotted.png) 0 0 repeat-x;
height: 1px;
border: none;
}
/*
* highlighted div and span tags
*/
span.note,
span.info,
span.alert,
span.download,
span.tip { display: block; }
div.note, span.note {
margin: 10px 0px 10px 0px;
padding: 5px 10px 5px 10px;
background: #E4EBF1;
border-top: 1px solid #D4D9DE;
border-bottom: 1px solid #D4D9DE;
text-align:justify;
text-shadow: 0px 1px 0px rgba(255,255,255,1);
}
div.info, span.info,
div.alert, span.alert,
div.download, span.download,
div.tip, span.tip {
margin: 10px 0px 10px 0px;
padding: 8px 10px 8px 40px;
text-shadow: 0px 1px 0px rgba(255,255,255,1);
}
div.info, span.info {
background: #E4EBF1 url(../images/typography/box_info.png) 8px 5px no-repeat;
border-top: 1px solid #D4D9DE;
border-bottom: 1px solid #D4D9DE;
}
div.alert, span.alert {
background: #FFE6DF url(../images/typography/box_alert.png) 8px 5px no-repeat;
border-top: 1px solid #FFD9CF;
border-bottom: 1px solid #FFD9CF;
}
div.download, span.download {
background: #f5faeb url(../images/typography/box_download.png) 8px 5px no-repeat;
border-top: 1px solid #D6EBCD;
border-bottom: 1px solid #D6EBCD;
}
div.tip, span.tip {
background: #FDF9E3 url(../images/typography/box_tip.png) 8px 5px no-repeat;
border-top: 1px solid #FAE7BE;
border-bottom: 1px solid #FAE7BE;
}
/*
* p tag with dropcaps
*/
p.dropcap:first-letter {
display: block;
margin: 7px 4px 0px 0px;
float: left;
font-size: 280%;
font-family: Georgia, "Times New Roman", Times, serif;
}
/*
* tables
*/
table.listing {
width: 100%;
margin-bottom: 30px;
font-size: 11px;
}
table.listing thead th {
height: 30px;
padding: 5px;
border-bottom: 1px solid #c8c8c8;
background: none;
vertical-align: top;
font-size: 14px;
font-weight: normal;
}
table.listing tbody td {
height: 20px;
padding: 5px;
border-bottom: 1px solid #c8c8c8;
}
table.listing tr.odd td { background: #f0f0f0; }
table.listing tr.even td { background: #ffffff; }
table.listing td.bold {
font-weight: bold;
font-size: 12px;
}
/*
* blockquotes
*/
blockquote { font-family: Georgia, "Times New Roman", Times, serif; }
q.blockquote {
margin: 10px 0 10px 15px;
font-family: Georgia, "Times New Roman", Times, serif;
font-style: italic;
font-size: 130%;
}
q.blockquote:first-letter { font-size: 150%; }
q.blockquote:before,
q.blockquote:after { content: ""; }
blockquote.quotation {
margin: 10px 0px 10px 0px;
padding: 10px 35px 10px 35px;
border: none;
background: url(../images/typography/blockquote_start.png) 0 0 no-repeat;
text-align:justify;
}
blockquote.quotation p {
margin: 0px -35px -10px 0px;
padding: 0px 35px 10px 0px;
background: url(../images/typography/blockquote_end.png) 100% 100% no-repeat;
}
/*
* floating boxes
*/
body .inset-left {
margin: 15px 15px 10px 0px;
float: left;
}
body .inset-right {
margin: 15px 0px 10px 15px;
float: right;
}