Alternatively, I was to solve your problem, I would use tables, but I suppose you would like it tableless, right?
Tables are not designed for layout. CSS is designed for layout.
Tables add unnecessary bloated code, CSS is considerably slimmer and more efficient.
Tables are great if you have tablature data, but are misused for layout.
So say if you have a main box which was 450px wide. There are 5 coloms each 100px wide. If you try and fit them all in 1 line, will it only fir 4 in and the 5th box will be shifted to the next line because it is 100px and there is only 50px left ?
Basically... if you set the width then that is it. You can't squeeze 500px into a 450px box without it line feeding.
And what is the clear tag
Sorry, that was unnecessary to put in there. That clear tag will clear the float; either left, right or all. So if you had another div that you wanted to start fresh on the next area you could tell it to clear: <then one of the choices here>;
In my <div> tags, when i write like im doing now and press enter
There is a big gap. Is there any css tag that you can like set when you press enter, how many lines it goes down like ill press enter.
So there is no BIG gap between the lines ?
Sounds like your editor is inserting that. What are you using? Open up your code with something other than a GUI type editor (Dreamweaver for example) and I bet you will see either one or two <br /> in there or a <p>nbsp;</p>... Remove those and your big gap is gone. I would check your editor.. it's most likely taking enter presses as breaks and inserting the code.