SitePoint Sponsor

User Tag List

Results 1 to 6 of 6
  1. #1
    SitePoint Zealot Fruit & Veg's Avatar
    Join Date
    May 2000
    Location
    UK
    Posts
    114
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Question Table Heights in NN7 & Opera 7

    I thought I'd be a good little boy and make sure a new site is 'perfect' in all three main browsers, the trouble is I can't afford to lose much more hair.

    I'm specifying a table height, thus -

    <tr><td width="100%" height="1"></td></tr>

    It's just a little table inbetween two main ones.
    It aligns in Explorer. It doesn't in Opera or Netscape.

    The absolute bizarre thing is that if I change the height to 10 or 100 it aligns in Opera and Netscape, but if you input a number below 10 it doesn't work!
    I thought, hang on, maybe it only works with 'whole' numbers (divisible by 10 for some strange reason) but I tried 76 and that works too.

    Opera and Netscape seem to default at 10 and refuse to go any lower.

    Is this really the case?
    What's a way out of it?
    USBtastic - UK Gadgets Blog
    SmartGeezer - UK Men's Clothing Blog
    Individualitee - Great Tshirts
    Shiola - Complete Waste of Time

  2. #2
    ☆★☆★ silver trophy vgarcia's Avatar
    Join Date
    Jan 2002
    Location
    in transition
    Posts
    21,236
    Mentioned
    1 Post(s)
    Tagged
    1 Thread(s)
    Why do you need a 1-pixel table cell anyway? If you want some extra padding or a border effect you can use CSS and save yourself some frustration.

  3. #3
    "Of" != "Have" bronze trophy Jeff Lange's Avatar
    Join Date
    Jan 2003
    Location
    Calgary, Canada
    Posts
    2,063
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    While I agree with vgarcia I think this can fix your problem:

    HTML Code:
    <td width="100%" style="height:1px font-size:0;">
    Who walks the stairs without a care
    It shoots so high in the sky.
    Bounce up and down just like a clown.
    Everyone knows its Slinky.

  4. #4
    SitePoint Zealot Fruit & Veg's Avatar
    Join Date
    May 2000
    Location
    UK
    Posts
    114
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I don't want padding or a border on the left or right hand sides of the cell.

    The above didn't work in NN7 or OP7, nor does;

    <tr><td width="100%" height="1" style="font-size: 1px">&nbsp;</td></tr>

    Thanks anyway but I'm really not that concerned to keep on trying.

    Cheers.
    USBtastic - UK Gadgets Blog
    SmartGeezer - UK Men's Clothing Blog
    Individualitee - Great Tshirts
    Shiola - Complete Waste of Time

  5. #5
    SitePoint Addict
    Join Date
    Dec 2002
    Posts
    386
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    a. don't use tables for layout!
    ok sermon over
    b. you need to put something in the table cell... but something small, like a 1px spacer gif, this is because nn7 and op7 follow the rules. The use of a space will not work since that space will still be the height of your font, either decalred or default. Thus use a 1px high transparent gif.
    c. don't use tables for layout

  6. #6
    SitePoint Member
    Join Date
    Sep 2003
    Location
    USA
    Posts
    12
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Are yousing a DOCTYPE? Check this link:
    http://devedge.netscape.com/viewsource/2002/img-table/


Bookmarks

Posting Permissions

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