I've been out of it for a while so this is likely a rookie question that
I've forgotten the answer to. I'm working on a section that makes a DIV
of a certain size with scrolling contents. I wanted to make different
DIVs with the difference being their border color. And instead of
writing a larger section of CSS three times I did it like so:
#invitelist div.window {
display: block;
width: 98%;
height: 100px;
overflow: auto;
padding: 5px;
background-color: #ffffff;
color: #000000;
}
#invitelist div.window.redframe {
border: 3px ridge #b90025;
}
Originally, I tried:
#invitelist div .window
and
#invitelist div .window .redframe
But could only get it to work by taking out all the spaces so I would up
with:
#invitelist div.window.redframe
I don't get why this didn't work with the spaces. My understanding was
that with the spaces it targets anything with a class of redframe inside
anything with a class of window inside a DIV inside a DIV with an ID of
invitelist. What I would up with works but seems to me that it will only
target a DIV that has the class window and redframe. The distinction is
subtle.
Refresh my memory, please...
Thanks,
Mike
______________________________________________________________________
css-discuss [css-d@lists.css-discuss.org]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
List policies -- http://css-discuss.org/policies.html
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/