need style sheet help

akohl's picture

They have: 117 posts

Joined: Feb 2001

I need help with this style sheet.
I'm basically trying to do layout with css as opossed to tables. But I'm having trouble.

Can someone explain why the layout on this home page isn't working?

readefrat.com

The class selector just doesn't seem to match. Why not?

Here is relevant stylesheet;

/*
text block selectors
*/
H1
{
font-family: arial;
font-size: 50;
}

H3
{
font-family: arial;
font-size: 24;
}
/*
page structure selectors
*/
BODY.first
{
background-color: #6633FF;
text-align:center;
}
BODY.FIRST DIV
{

margin: 20;
background-color:#FFFF00;
width:500;
height: 300;
}
BODY.ARTICLES
{
margin: 15;
background-color: red;

/*
collumn positioning classes. "right" and "left" can be used to divide an area into
two equal collums. They can be used inside the the "two thirds left" classed division
to make a three collum layout. These can be used seperately or together for
internal header and footer layout as well as division of collums on the start page.
*/

.one_third_left
{
width: 33%;
float:left;
}
.two_thirds_right
{
width: 65%;
float: right;
text-align: left;

}

.left
{
width: 48%;
text-align:center;

}

.right
{
width: 48%;
text-align:center;
background-color: blue;
}

Andy Kohlenberg
Jerusalem, Israel

Suzanne's picture

She has: 5,507 posts

Joined: Feb 2000

You can't use underscores in the class names.

Smiling Suzanne

akohl's picture

They have: 117 posts

Joined: Feb 2001

I've sorted it out now, more or less.
Thanks.

But its strange, some of my selectors were matching, even though I was using underscores in the class names.

Andy

Andy Kohlenberg
Jerusalem, Israel

Suzanne's picture

She has: 5,507 posts

Joined: Feb 2000

Anyway, the underscores "may cause most browsers to ignore it" -- it's a bit hit and miss.

Glad it's working!

Smiling Suzanne

Want to join the discussion? Create an account or log in if you already have one. Joining is fast, free and painless! We’ll even whisk you back here when you’ve finished.