View Full Version : Div coding help [+rep]
For the past three days iv'e been trying to code my layout in divs,
No good as of yet.
Anyway, i would like to see how all you coders position the divs etc, so i can figure out what i am doing wrong and what i need to include.
So if you have any old coded layout that you don't need could i please borrow it for educational purposes?
+rep for those who do
BuaxDesigns
07-10-2008, 01:40 AM
I suggest you read some tutorials about DIVS etc.
http://www.w3schools.com/tags/tag_DIV.asp
http://www.yourhtmlsource.com/stylesheets/csslayout.html
http://www.wmtips.com/CSS/replace-tables-with-divs-css-609.htm
I postition my divs like this:
{position: choice; top: 0px; bottom: 0px; left: 0px; right: 0px; }
Stole off one of the tutorials listed above; But still, that's how I do it, unsure on other days to do it, but I'm sure their are some. :)
Good luck learning DIV coding. :)
Tomathey
07-10-2008, 06:18 AM
Most of the time I use float: left; because most of my layouts have 3 columns.
I can't really explain it, but just read up on positioning divs ect. I didn't use any tutorials, I had to teach myself, but thats what I would suggest. :)
If it's for a layout then you probably need to use "float: left;" and "float: right;".
I do this:
float: left; - This is for making it float to the lft (Using alot)
float: right; - This is for making it float to the right (Ain't using it alot)
margin: auto; - This is for centering the things
Decode
08-10-2008, 03:49 PM
I suggest you read some tutorials about DIVS etc.
http://www.w3schools.com/tags/tag_DIV.asp
http://www.yourhtmlsource.com/stylesheets/csslayout.html
http://www.wmtips.com/CSS/replace-tables-with-divs-css-609.htm
I postition my divs like this:
{position: choice; top: 0px; bottom: 0px; left: 0px; right: 0px; }
Stole off one of the tutorials listed above; But still, that's how I do it, unsure on other days to do it, but I'm sure their are some. :)
Good luck learning DIV coding. :)
I would not recommend using that method as you can't do expanding divs.
The best way to do it is to make a container div, then make 3 divs inside it all floating left (to get 3 columns). Never use float: right!
Want to hide these adverts? Register an account for free!
Powered by vBulletin® Version 4.2.5 Copyright © 2024 vBulletin Solutions Inc. All rights reserved.