1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

3 Columns Look Help!

Discussion in 'CSS' started by gobbly2100, Jul 26, 2007.

  1. #1
    I am very new to CSS and just wondered how I get the 3 column look, here is what I done so far but I don't think it is correct.

    Here is the HTML I thought I had to do

    <div class="col1"></div>
    <div class="col2"></div>
    <div class="col3"></div>
    Code (markup):
    And here is what I got in my CSS for it

    .col1 {
    line-width: 20%;
    }
    
    .col2 {
    line-width: 60%;
    }
    
    .col3 {
    line-width: 20%;
    }
    Code (markup):
    If this is not right then what is the correct way of getting this look?
     
    gobbly2100, Jul 26, 2007 IP
  2. benihana

    benihana Peon

    Messages:
    19
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #2
    there are many ways to do this, depedning on your exact requirements. unfortunately none as simple as the code you have.

    try here: http://bluerobot.com/web/layouts/index.html

    dissect them and learn from them

    btw: its just width not line-width
     
    benihana, Jul 26, 2007 IP
  3. just-4-teens

    just-4-teens Peon

    Messages:
    3,967
    Likes Received:
    168
    Best Answers:
    0
    Trophy Points:
    0
    #3
    It would need to be more like this

    
    <div class="wrap">
    <div class="col1"></div>
    <div class="col2"></div>
    <div class="col3"></div>
    <div>
    
    Code (markup):
    CSS

    
    .wrap {width:900px;}
    .col1 {
    line-width: 18%;
    float:left;
    margin:2px;
    }
    
    .col2 {
    line-width: 59%;
    float:left;
    margin:2px;
    }
    
    .col3 {
    line-width: 19%;
    float:left;
    margin:2px;
    }
    
    Code (markup):
     
    just-4-teens, Jul 26, 2007 IP
  4. webdesigner

    webdesigner Well-Known Member

    Messages:
    489
    Likes Received:
    14
    Best Answers:
    0
    Trophy Points:
    110
  5. Dan Schulz

    Dan Schulz Peon

    Messages:
    6,032
    Likes Received:
    436
    Best Answers:
    0
    Trophy Points:
    0
    #5
    Actually, if you take a look at my "All You Need to Know About SEO" thread (link is in my signature) I have a three column layout that's been released into the public domain that you can use. If you need help understanding any of it, feel free to ask me and I'll do my best to help.
     
    Dan Schulz, Jul 26, 2007 IP