...

View Full Version : CSS Help



Strife
11-05-2006, 02:04 PM
The problem here is I can't get the ls and rs divs to expand with the masterdivs content.

CSS

/* CSS StyleSheet */
body {
text-align: center;
background-color:#d8c379;
background-image:url(images/bodybg.gif);
background-repeat:repeat-x;
margin-top:0px;
}
#wrapper {width: 760px; margin: 0 auto; text-align: left; padding:0 0 0 0;}

#ls {
width:17px;
background-image:url(images/ls.gif);
background-repeat:repeat-y;
padding:0 0 0 0;
float:left;
}

#rs {
width:17px;
background-image:url(images/rs.gif);
background-repeat:repeat-y;
padding:0 0 0 0;
float:right;
}

#masterdiv {
width: 726px;
float:left;
padding:0 0 0 0;
}

.clear {
clear: both;
}


HTML

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Naruto FZ</title>
<link rel="stylesheet" type="text/css" href="style.css">
</head>

<body>
<div id="wrapper">
<div id="ls"></div>
<div id="rs"></div>
<div id="masterdiv">TEST<br />Test<br />TeSt<br />tEST<br /></div>
<div class="clear"></div>
</div>
</body>
</html>

BonRouge
11-05-2006, 02:26 PM
Do you mean expand downwards? You might want to use faux columns. Here's an example: http://bonrouge.com/3c-hf-fluid-lc.php
Or you might want to do it another way: http://www.positioniseverything.net/articles/onetruelayout/

Strife
11-05-2006, 02:47 PM
Here is an image to show what I mean, this what I want to happen:

http://img174.imageshack.us/img174/8471/exampleiv5.gif
I want those to siderbars to expand like that with the central div.

In FF the sidebars don't show at all unless I put something in them like &nbsp;, they show up to the end of the first line of text but don't expand any further.

BonRouge
11-05-2006, 03:17 PM
That's right. Please read my last post.

Strife
11-05-2006, 03:22 PM
Thanks, got it working.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum