Problem with CSS table in Firefox

Discussion in 'HTML' started by Hvid Hat, Feb 26, 2008.

  1. Hvid Hat

    Hvid Hat Guest

    Hello

    I'm trying to set up a table with CSS but it doesn't look correctly in Firefox.
    Firstly I've got the table as I want it (using table, tr, td) and below is
    the CSS table that doesn't look correct in Firefox. The second line of "On
    this very day something happened" is written below the date. It should stay
    in its "own" column. How do I get it to do that?


    http://hvidhat.users.whitehat.dk/table.htm
     
    Hvid Hat, Feb 26, 2008
    #1
    1. Advertising

  2. Hvid Hat

    Els Guest

    Hvid Hat wrote:

    > I'm trying to set up a table with CSS but it doesn't look correctly in Firefox.
    > Firstly I've got the table as I want it (using table, tr, td) and below is
    > the CSS table that doesn't look correct in Firefox. The second line of "On
    > this very day something happened" is written below the date. It should stay
    > in its "own" column. How do I get it to do that?
    >
    > http://hvidhat.users.whitehat.dk/table.html


    Float div.text as well, or, give it a left margin as wide as needed
    for the floated div.date.

    At the same time though, the table is a better construction for what
    you are doing than the divs. The dates belong to the texts, so there
    is a connection, both vertical (all dates) as horizontal (dates and
    texts). I'd just use a table if I were you.

    --
    Els http://locusmeus.com/
     
    Els, Feb 26, 2008
    #2
    1. Advertising

  3. Hvid Hat wrote:
    > Hello
    >
    > I'm trying to set up a table with CSS but it doesn't look correctly in
    > Firefox. Firstly I've got the table as I want it (using table, tr, td)
    > and below is the CSS table that doesn't look correct in Firefox. The
    > second line of "On this very day something happened" is written below
    > the date. It should stay in its "own" column. How do I get it to do that?
    >
    > http://hvidhat.users.whitehat.dk/table.html
    >
    >

    It is doing exactly what you have "told" it to do...

    add this and see what is happening.

    ..table { background-color: #f88; }
    ..date { background-color: #8f8; }
    ..text { background-color: #88f; }

    If another browser, I bet IE, is doing something different then it is IE
    that is incorrect.

    1) You need to learn what the "float" property does. It does not
    preserve the rectangle of the floated block but rather flows it around
    the non-floated blocks. It is *supposed* to do that.

    2) It is *not* CSS *or* TABLES! You can use a table with CSS. What you
    should not do is use table elements to layout non-tabular content of a
    page, i.e., put a logo here and put a menu there... It looks like you
    have tabular data--use a table.


    --
    Take care,

    Jonathan
    -------------------
    LITTLE WORKS STUDIO
    http://www.LittleWorksStudio.com
     
    Jonathan N. Little, Feb 26, 2008
    #3
  4. Hvid Hat

    mrcakey Guest

    "Hvid Hat" <vil_ikke@have_spam.dk> wrote in message
    news:...
    > Hello
    >
    > I'm trying to set up a table with CSS but it doesn't look correctly in
    > Firefox. Firstly I've got the table as I want it (using table, tr, td) and
    > below is the CSS table that doesn't look correct in Firefox. The second
    > line of "On this very day something happened" is written below the date.
    > It should stay in its "own" column. How do I get it to do that?
    >
    > http://hvidhat.users.whitehat.dk/table.html
    >
    >


    Are you doing it as some sort of learning exercise? Cos if you have stuff
    you want to put in a table, put it in a table. Getting a table look with
    CSS for the sake of is just masochistic!

    +mrcakey
     
    mrcakey, Feb 26, 2008
    #4
  5. Hvid Hat

    Lew Loo Guest

    On 26 Feb 2008, Hvid Hat wrote:

    > Hello
    >
    > I'm trying to set up a table with CSS but it doesn't look correctly in
    > Firefox. Firstly I've got the table as I want it (using table, tr, td)
    > and below is the CSS table that doesn't look correct in Firefox. The
    > second line of "On this very day something happened" is written below
    > the date. It should stay in its "own" column. How do I get it to do
    > that?
    >
    >
    > http://hvidhat.users.whitehat.dk/table.html
    >
    >
    >


    Add to css div.text { width: 175px;float:right;} and div.table div {
    clear:right; }

    --
    LL
     
    Lew Loo, Feb 26, 2008
    #5
  6. Hvid Hat

    dorayme Guest

    In article <fq20ed$oen$>,
    "mrcakey" <> wrote:

    > Getting a table look with
    > CSS for the sake of is just masochistic!


    If you want a table-look to non-tabular layout, are you saying
    that this is a bad thing to want? Or that if you want it, go
    ahead and use a table anyway? Or is it like that Clinton should
    have resisted Lewinsky altogether no matter how much he wanted
    her. And, of course, the deeper question, would he have been
    masochistic to do so?

    --
    dorayme
     
    dorayme, Feb 26, 2008
    #6
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. David Williams
    Replies:
    2
    Views:
    1,156
    Jacob Yang [MSFT]
    Aug 12, 2003
  2. Eric
    Replies:
    4
    Views:
    757
    clintonG
    Dec 24, 2004
  3. Replies:
    3
    Views:
    10,420
  4. Replies:
    3
    Views:
    927
    richard
    Sep 24, 2006
  5. vitay
    Replies:
    8
    Views:
    568
    Stan McCann
    Nov 9, 2006
Loading...

Share This Page