Box Model Hack?

Discussion in 'CSS' started by jwalker80, Feb 1, 2007.

  1. #1
    Hi

    #button
    {
    width:80px;
    height:48px;
    float:left;
    background-image:url(..images/blank.gif);
    }

    I have this code that needs to be modified for IE to work, the width has to be reduced for the button divs to fit in IE. I think this has to do with the "box model" but im not sure how to implement it, anyone help?
     
    jwalker80, Feb 1, 2007 IP
  2. the_pm

    the_pm Peon

    Messages:
    332
    Likes Received:
    33
    Best Answers:
    0
    Trophy Points:
    0
    #2
    What isn't working? I don't see anything within that one snippet that would cause IE any problems. You're not invoking the box model (no padding, no margins, no borders), and the markup you're using is very basic CSS1 that even IE understands.

    Can you link to a page where you're seeing something you feel should be different?
     
    the_pm, Feb 1, 2007 IP
  3. Colbyt

    Colbyt Notable Member

    Messages:
    3,224
    Likes Received:
    185
    Best Answers:
    0
    Trophy Points:
    210
    #3
    No the hack makes it work in FF and others. You make it look right in IE and then fix it for the other browsers that really read the css file. The issue is the way that IE handles the padding issues.

    I think what you are looking for is here.

    If I misunderstood your request I will apologize in advance.
     
    Colbyt, Feb 1, 2007 IP
  4. kk5st

    kk5st Prominent Member

    Messages:
    3,497
    Likes Received:
    376
    Best Answers:
    29
    Trophy Points:
    335
    #4
    I'll go even further. Use a complete and proper DTD, to trigger standards mode, and IE6&7 will play fairly nice with other browsers. Just blow IE5.x completely off. It is nearly 10 years out of date, and should be supported only with extra compensation from the client. Big compensation.

    cheers,

    gary
     
    kk5st, Feb 1, 2007 IP