3 replies [Last post]
mmem700
Offline
newbie
Last seen: 13 years 40 weeks ago
Timezone: GMT-3.5
Joined: 2009-05-28
Posts: 5
Points: 0

I've attached a screenshot showing firebug displaying the CSS in precedence order in Firefox. I have also include my CSS file.

I'm looking at the (blue) highlighted anchor tag on the left.

The CSS ordering on the right shows that

p a:hover,a:active

is higher in precedence than

#menubar_TD a:hover,a:active

yet, the highlighted tag IS NOT a descendant of a

tag.

What am I missing here?

Thanks in advance.

#header_TABLE {
	width: 700px;
	margin-top: 0px;
	margin-right: auto;
	margin-bottom: 0px;
	margin-left: auto;
	height: 100px;
	border: 1px solid #CCCCCC;
}
#header_TD {
}
#menubar_TABLE {
	width: 700px;
	margin-top: 0px;
	margin-right: auto;
	margin-bottom: 0px;
	margin-left: auto;
	border: 1px solid #62804D;
	height: 24px;
	background-color: #DDDDDD;
}
#menubar_TD {
	text-align: center;
}
#menubar_TD>a:link,a:visited {
	text-decoration: none;
	color: #333333;
}
 
#menubar_TD>a:hover,a:active {
	text-decoration: underline;
}
TD:firstchild {
	background-color:#CC6600
}
 
 
 
#body_TABLE {
	margin-top: 15px;
	margin-right: auto;
	margin-bottom: 0px;
	margin-left: auto;
	width: 700px;
}
#body_TD {
	border-top-width: 2px;
	border-right-width: 2px;
	border-bottom-width: 2px;
	border-left-width: 2px;
	border-top-style: solid;
	border-right-style: solid;
	border-bottom-style: solid;
	border-left-style: solid;
	border-top-color: #C4AC7E;
	border-right-color: #C4AC7E;
	border-bottom-color: #C4AC7E;
	border-left-color: #C4AC7E;
	text-align: left;
	vertical-align: top;
	padding: 15px;
}
#footer_TABLE {
	width: 700px;
	margin-top: 15px;
	margin-right: auto;
	margin-bottom: 0px;
	margin-left: auto;
}
#footer_TD {
	text-align: center;
	font-family: Arial, Helvetica, sans-serif;
	font-size: 10px;
	font-weight: normal;
	color: #9E8A65;
}
 
 
p>a:link,a:visited {
	color: #FF6600;
	text-decoration: none;
}
p>a:hover,a:active {
	color: #669933;
	text-decoration: underline;
}
 
 
.sb_Area {
	font-family: Georgia, "Times New Roman", Times, serif;
	font-size: 18px;
	font-weight: bold;
	color: #65839E;
	border: 1px solid #C4AC7E;
	background-color: #EBDB96;
	margin: 0px;
	padding-top: 5px;
	padding-right: 0px;
	padding-bottom: 5px;
	padding-left: 15px;
}
.sb_Area-cur {
	background-color: #C4AC7E;
	margin: 0px;
	padding-top: 5px;
	padding-right: 0px;
	padding-bottom: 5px;
	padding-left: 15px;
	font-family: Georgia, "Times New Roman", Times, serif;
	font-size: 18px;
	font-weight: bold;
	color: #65839E;
}
.sb_Chapter {
	font-family: Tahoma, Verdana, sans-serif;
	font-size: 11px;
	font-weight: bold;
	color: #666666;
	margin: 0px;
	padding-top: 2px;
	padding-right: 0px;
	padding-bottom: 2px;
	padding-left: 15px;
}
h1 {
	font-family: Georgia, "Times New Roman", Times, serif;
	font-size: 28px;
	font-weight: bold;
	text-align: center;
}
h2 {
	font-family: Georgia, "Times New Roman", Times, serif;
	font-size: 22px;
	font-weight: bold;
	text-align: center;
}
h3 {
	font-family: Georgia, "Times New Roman", Times, serif;
	font-size: 18px;
	font-weight: bold;
}
h4 {
	font-family: Verdana, Arial, Helvetica, sans-serif;
	font-size: 14px;
	font-weight: bold;
}
h5 {
	font-family: Verdana, Arial, Helvetica, sans-serif;
	font-size: 12px;
	font-weight: bold;
}
h6 {
	font-family: Verdana, Arial, Helvetica, sans-serif;
	font-size: 12px;
	font-style: italic;
	font-weight: normal;
}
 
 
p {
	font-family: Verdana, Arial, Helvetica, sans-serif;
	font-size: 12px;
	font-style: normal;
	font-weight: normal;
}
ul {
	font-family: Verdana, Arial, Helvetica, sans-serif;
	font-size: 12px;
	font-style: normal;
	font-weight: normal;
}
li {
}

AttachmentSize
Firebug Screenshot.jpg181.63 KB
CSS List.jpg29.41 KB
mmem700
Offline
newbie
Last seen: 13 years 40 weeks ago
Timezone: GMT-3.5
Joined: 2009-05-28
Posts: 5
Points: 0

Example Page Posted - This makes it easy to see...

If you visit this link:

http://chemtrailsconnect.com/stories/My-Chemtrail-Story/test.html

You will see two links:

"The Global Vaccine Agenda"
"The Thimerosal-Autism Coverup"

The first one, if you view it in Firebug (right-click and then click "inspect element"), will give this as the first CSS rule that applies:

td#menubar_TD a:hover,a:active {}

Can anyone tell me how this rule could possible apply to either of the above links when neither of the links are within the element?

I have researched this all night and am still baffled.

wolfcry911
wolfcry911's picture
Offline
Guru
MA, USA
Last seen: 9 years 13 weeks ago
MA, USA
Timezone: GMT-5
Joined: 2004-09-01
Posts: 3224
Points: 237

First of all, why are you

First of all, why are you using a table for layout?

Secondly, you're selectors are wrong. When using a comma delimited list, the selectors do not retain the parent of the previous selector.

p>a:hover,a:active {
	color: #669933;
	text-decoration: underline;
}
 
#menubar_TD>a:hover,a:active {
	text-decoration: underline;
}
is not the same as:
p>a:hover, p>a:active {
	color: #669933;
	text-decoration: underline;
}
 
#menubar_TD>a:hover, #menubar_TD>a:active {
	text-decoration: underline;
}
so in essence you've styled all active psuedo class anchors.

mmem700
Offline
newbie
Last seen: 13 years 40 weeks ago
Timezone: GMT-3.5
Joined: 2009-05-28
Posts: 5
Points: 0

Thanks. That's that answer I

Thanks. That's that answer I was looking for.