Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 4 of 4

Thread: height of <div>

  1. #1
    New Coder
    Join Date
    Aug 2002
    Location
    newb coder
    Posts
    10
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Question height of <div>

    Heya,

    I have the following:

    PHP Code:
    .bar height5pxbackground#000000 }

    <div class="bar"></div
    For some reason tho, the <div> won't appear on the page smaller than 17 pixels. I can make it larger than that, but nothing smaller. Is this a limitation of div, or of IE 6?

    Thanks.

  • #2
    New Coder
    Join Date
    Aug 2002
    Location
    newb coder
    Posts
    10
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Solved!

    I spoke too soon. It seems that the <div> wouldn't allow it to go smaller than the default text size (even though there was no text present). Setting font-size: 1px; in my style class fixed it.

  • #3
    Senior Coder
    Join Date
    Jul 2002
    Posts
    1,628
    Thanks
    0
    Thanked 0 Times in 0 Posts
    glad we could help!

  • #4
    New Coder
    Join Date
    Jun 2002
    Posts
    30
    Thanks
    0
    Thanked 0 Times in 0 Posts
    The correct way would be to add overflow:hidden; to your class.


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •