/    Sign up×
Community /Pin to ProfileBookmark

Background Color Problems

Hey guys,

I’m having a rather bizarre issue with background colors in a web application I’m working with.

I’m setting a background-color for a tr element like so:

[CODE]tr.odd td.calendarBlanks, tr.odd td.calendarEvent, tr.odd td.conferenceEvent
{
background-color: #F3F3F3;
}
tr.even td.calendarBlanks, tr.even td.calendarEvent, tr.even td.conferenceEvent
{
background-color: #FFFFFF;
}
[/CODE]

[code=html] <tr class=”odd”>
<td class=”calendarEvent”>
<a href=”#” onclick=”openSummaryPopup(‘eventSummaryPopup.do?eventName=’ + this.innerHTML)”>Calendar Event Goes Here</a>
</td>
</tr>
<tr class=”odd”>
<td class=”conferenceEvent”>Conferences</td>
</tr>
<tr class=”even”>
<td class=”calendarEvent”>
<a href=”#” onclick=”openSummaryPopup(‘eventSummaryPopup.do?eventName=’ + this.innerHTML)”>Calendar Event Goes Here</a>
</td>
</tr>
<tr class=”even”>
<td class=”conferenceEvent”>Conferences</td>
</tr>[/code]

The problem is that it doesn’t show this background color for the odd rows, but if I change it to a color slightly darker, like #E1E1E1, it appears. Now the application is large and on this particular page it calls 6 different style sheets for different page tiles. So I can’t post those, but I will tell you that I’ve gone searching throughout the stylesheets and there is no reference to any tr td elements that would even have the slightest chance of changing the the elements style to something else.

I’m wondering if anyone else has run into a situation like this in the past. The error occurs in both Mozilla and IE, which leads me to believe something I’m doing is obviously wrong.

Any insight or help is appreciate, I realize I’m not providing much code, but please know I would if I could.

to post a comment
CSS

1 Comments(s)

Copy linkTweet thisAlerts:
@FangJan 13.2006 — You have either missed a css rule or a [URL=http://www.molly.com/2005/10/06/css2-and-css21-specificity-clarified/]specificity[/URL] problem.
×

Success!

Help @Rezon spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 6.16,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @nearjob,
tipped: article
amount: 1000 SATS,

tipper: @meenaratha,
tipped: article
amount: 1000 SATS,

tipper: @meenaratha,
tipped: article
amount: 1000 SATS,
)...