[Help] CSS Inline Box Style

Discussion in 'CSS' started by Smurtey, Feb 10, 2010.

  1. #1
    Hello everyone,

    I have been trying to make a box with an inline style (see the picture below). I have been searching for the answer for two days now... and I know someone out there know the answer. That's why I am asking you here on DP. If you find any useful links, please show me, since I really need help with this!

    [​IMG]
    ^ This is the box style I want to create.

    Thanks,
    Filip
     
    Smurtey, Feb 10, 2010 IP
  2. s_ruben

    s_ruben Active Member

    Messages:
    735
    Likes Received:
    26
    Best Answers:
    1
    Trophy Points:
    78
    #2
    If I understood you correctly, it is that what you wanted:

    
    <html>
    
    <head>
      <title>Box</title>
      <style>
      #box{
        width: 150px;
        height: 150px;
        padding: 20px;
        background: #8C0000;
      }
    
      #inline_box_border{
        width: 152px;
        height: 152px;
        padding: 1px;
        background: #770000;
      }
    
      #inline_box{
        width: 150px;
        height: 150px;
        background: #AA0000;
        border: 1px solid #D00000;
      }
      </style>
    </head>
    
    <body>
    
    <div id="box">
        <div id="inline_box_border">
            <div id="inline_box">
    
            </div>
        </div>
    </div>
    
    </body>
    
    </html>
    
    Code (markup):
     
    s_ruben, Feb 11, 2010 IP
  3. Smurtey

    Smurtey Member

    Messages:
    52
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    41
    #3
    That was exactly what I wanted!
    Thank you so much!

    Kind regards,
    Filip
     
    Smurtey, Feb 11, 2010 IP