Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Two column CSS

Status
Not open for further replies.

mousematt

MIS
Feb 5, 2001
102
0
0
GB
Hi I have a slight problem (apart from my lack of knowledge problem!). If you take a look at
you should be able to see that the tables in the main content section move to the left when they get below the menu divs on the left.

Could anyone tell me where I've gone wrong on this as I want it to continue straight down. I'm new to CSS so sorry for the lack of info not sure what else to post.
 
You haven't done anything wrong, that is just how things are. While there is the floated box, the elements will position themselves next to that, when that is gone, they will flush against the left edge. You can change that by adding margin on the left side that is equivalent to the gap you want to have. Margin remains unaffected by the floated element.

___________________________________________________________
[small]Do something about world cancer today: PACT[/small]
 
Cool, thanks for the reply, which element would I add the margin to though?? Sorry for being dull!!
 
Looks like you figured it out. I would put the margin on an element that is wrapped around all the three tables, being a div (if form needs to be wrapped around all three tables, that could work as well) -- remember, try to use only the elements that have semantic value on your page.

___________________________________________________________
[small]Do something about world cancer today: PACT[/small]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top