Specify basic paragraph text, lists and tables

Discussion in 'CSS' started by nuts, Dec 6, 2006.

  1. #1
    Hi guys,

    i want my basic paragraph text, lists and tables to be dark green 12 point Verdana, but degrading to Arial, Helvetica and sans serif.

    This is what i have put in my CSS to achieve this, is this correct?

    p, li, td {
    font: 12pt verdana, arial, helvetica, sans-serif;
    color: #003300
    }

    If thats wrong could someone please correct me...

    Thanks.:)
     
    nuts, Dec 6, 2006 IP
  2. kk5st

    kk5st Prominent Member

    Messages:
    3,497
    Likes Received:
    376
    Best Answers:
    29
    Trophy Points:
    335
    #2
    I don't see anything in particular wrong with it. A better approach might be to depend on the user's UA and its default values. Most, if not all, browsers default to a 12pt font size, but as px. Too, the user might need or prefer a larger or smaller size. This leads to the following approach:
    
    body {
        font: 100% verdana, arial, helvetica, sans-serif;
        color: #080;
        }
    
    p, li, td {
        font-size: 1em;
        }
    Code (markup):
    cheers,

    gary
     
    kk5st, Dec 6, 2006 IP