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 8 of 8
  1. #1
    New Coder
    Join Date
    Jun 2002
    Posts
    24
    Thanks
    0
    Thanked 0 Times in 0 Posts

    table width="100%"

    hello there...

    Lets see... I have a html page were I want a table to occupy all the page width, so I write <table width="100%"... In a computer I run this page, using MSIE5, the vertical scrollbar didn't appear, and the table didn't occupied the entire page width, so there was a line with the background color of the page on the right side of the page.
    If I write <table width="103%"... for instance, we resolve this problem, but then we have problems when the vertical scrollbar appears

    Any ideas how to solve this?

  • #2
    Regular Coder
    Join Date
    Nov 2002
    Location
    Bristol, UK
    Posts
    932
    Thanks
    0
    Thanked 0 Times in 0 Posts
    ...that sounds odd. Are you sure that there is nothing else you are doing that might be influencing this behaviour...? In my experience, a table set to 100% should occupy 100%, regardless of the scrollbars (it should resize if they appear/disappear)

    ::] krycek [::
    ithium | SOAPI | SDP | PTPScript manual
    "ithium is a non-profit webhost, which is pretty much unique. The mission of ithium is to provide free hosting resources for worthwhile and needy non-profit projects, which otherwise may not be able to obtain such facilities. The money from commercial customers goes to maintain ithium's servers and further development."

  • #3
    Regular Coder bacterozoid's Avatar
    Join Date
    Jun 2002
    Location
    USA
    Posts
    490
    Thanks
    24
    Thanked 35 Times in 35 Posts
    First of all:

    <body topmargin="0" leftmargin="0">

    That gets rid of any area around the edge of the page. Also:

    margin:"0 0 0 0"

    I believe that is the CSS format for getting rid of margins.

    --

    As for your scrollbars...if you set to 100 percent, that's how much space the table takes up...in my recent tests it disallowed scrollbars if all the content was within the table and cut any off that went too far.

  • #4
    Regular Coder
    Join Date
    Nov 2002
    Location
    Bristol, UK
    Posts
    932
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Originally posted by bacterozoid
    margin:"0 0 0 0"

    I believe that is the CSS format for getting rid of margins.
    ...surely you mean:

    margin: 0;

    OR

    margin: 0 0 0 0;

    OR

    margin: 0px;

    ...or a different unit instead of px, however never ever in quotes

    margin="0" is a valid HTML attribute but in CSS there are no quotes.

    ::] krycek [::
    ithium | SOAPI | SDP | PTPScript manual
    "ithium is a non-profit webhost, which is pretty much unique. The mission of ithium is to provide free hosting resources for worthwhile and needy non-profit projects, which otherwise may not be able to obtain such facilities. The money from commercial customers goes to maintain ithium's servers and further development."

  • #5
    Regular Coder bacterozoid's Avatar
    Join Date
    Jun 2002
    Location
    USA
    Posts
    490
    Thanks
    24
    Thanked 35 Times in 35 Posts
    Hmm, I've ALWAYS used quotes in my css, though looking at W3 schools site I don't see any, lol. I guess my extensive HTML experience has carried over. I've never really liked not using quotes when you have a space within your attributes, doesn't look right...oh well, doesn't give me any errors, I'm happy.
    Last edited by bacterozoid; 12-12-2002 at 03:41 AM.

  • #6
    New Coder
    Join Date
    Jun 2002
    Posts
    24
    Thanks
    0
    Thanked 0 Times in 0 Posts
    well, I have already did margin=0 the HTML way and the CSS way.

    The thing is that... The browser opens the window as a default withot the scrollbar, wich is something that I've never seen, and independently of the leftmargi, topmargin, widthmargin, heightmargin... there is a line in the righthand side of the page with the page's bakcground color.

  • #7
    Regular Coder
    Join Date
    Nov 2002
    Location
    Bristol, UK
    Posts
    932
    Thanks
    0
    Thanked 0 Times in 0 Posts
    ...can you link to the page, or post the source?

    ::] krycek [::
    ithium | SOAPI | SDP | PTPScript manual
    "ithium is a non-profit webhost, which is pretty much unique. The mission of ithium is to provide free hosting resources for worthwhile and needy non-profit projects, which otherwise may not be able to obtain such facilities. The money from commercial customers goes to maintain ithium's servers and further development."

  • #8
    Senior Coder Nightfire's Avatar
    Join Date
    Jun 2002
    Posts
    4,265
    Thanks
    6
    Thanked 48 Times in 48 Posts
    <body style="overflow-y:hidden">


  •  

    Posting Permissions

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