SitePoint Sponsor

User Tag List

Results 1 to 12 of 12
  1. #1
    SitePoint Wizard Aes's Avatar
    Join Date
    Jun 2001
    Location
    Oklahoma
    Posts
    3,392
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Sometimes it's the easy things that are over one's head...

    All right, I'm using global stylesheets on my pages, i.e.
    Code:
    p.text { font-size : 11px ; font-face : arial, helvetica ; color : #000000 ; }
    What would I add to make a class italic? I've tried both font-weight and text-decoration but to no avail. Your help is much appreciated....
    Colin Anderson
    Ambition is a poor excuse for those without
    sense enough to be lazy.

  2. #2
    You talkin to me? Anarchos's Avatar
    Join Date
    Oct 2000
    Location
    Austin, TX
    Posts
    1,438
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    font-style:italic (from http://www.w3.org/TR/REC-CSS1#font-style)

  3. #3
    SitePoint Wizard Aes's Avatar
    Join Date
    Jun 2001
    Location
    Oklahoma
    Posts
    3,392
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Ahhh.... Many thanks Anarchos. I'll bookmark that addy as well!
    Colin Anderson
    Ambition is a poor excuse for those without
    sense enough to be lazy.

  4. #4
    Former Staff Member silver trophy Adam P.'s Avatar
    Join Date
    Apr 2001
    Location
    San Francisco
    Posts
    3,288
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Aes, another good reference site for CSS is:

    http://hotwired.lycos.com/webmonkey/...roperties.html

    A long, simple, easy to read list. And it's layed out nicely.

    CHECK IT OUT
    SPF Mentor/Advisor 2001-2003
    SPF Designer of the Year 2002
    SPF Graphic Designer of the Year 2003
    AdamPolselli.com

  5. #5
    SitePoint Wizard Aes's Avatar
    Join Date
    Jun 2001
    Location
    Oklahoma
    Posts
    3,392
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Thanks Swimm.
    ::adds link to bookmark depository::
    Colin Anderson
    Ambition is a poor excuse for those without
    sense enough to be lazy.

  6. #6
    SitePoint Wizard
    Join Date
    Jan 2001
    Location
    Milton Keynes, UK
    Posts
    1,011
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Be sure to change that 'font-face' to 'font-family' as well Aes.

  7. #7
    Former Staff Member silver trophy Adam P.'s Avatar
    Join Date
    Apr 2001
    Location
    San Francisco
    Posts
    3,288
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    another good idea would be to add "sans-serif" as the last font in your "font-family" attribute.

    Just in case
    SPF Mentor/Advisor 2001-2003
    SPF Designer of the Year 2002
    SPF Graphic Designer of the Year 2003
    AdamPolselli.com

  8. #8
    SitePoint Wizard Aes's Avatar
    Join Date
    Jun 2001
    Location
    Oklahoma
    Posts
    3,392
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Thank you shane, Swimm. Anything else? =)
    Colin Anderson
    Ambition is a poor excuse for those without
    sense enough to be lazy.

  9. #9
    Non-Member Kelar's Avatar
    Join Date
    Jul 2001
    Location
    Holland
    Posts
    79
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Just something minor, the ; at the end of the stylesheet is not needed.

    This will work as well:
    Code:
    p.text { font-size : 11px ; font-face : arial, helvetica ; color : #000000}

  10. #10
    SitePoint Wizard creole's Avatar
    Join Date
    Oct 2000
    Location
    Nashvegas Baby!
    Posts
    7,845
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Not "needed" but it's a good habit to get into putting it at the end of every individuyal declaration. That way you won't ever forget. My stylesheets are always the same:

    selector { attribute: value; }

    Always have the space between the content and the { } and always put a ; at the end of every attribute/value pair. It will keep you honest.
    Adobe Certified Coldfusion MX 7 Developer
    Adobe Certified Advanced Coldfusion MX Developer
    My Blog (new) | My Family | My Freelance | My Recipes

  11. #11
    Non-Member Kelar's Avatar
    Join Date
    Jul 2001
    Location
    Holland
    Posts
    79
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Okay, seems reasonable to me. Anyway, it was just something minor, as I already stated, maybe not even worth mentioning.

  12. #12
    SitePoint Wizard Aes's Avatar
    Join Date
    Jun 2001
    Location
    Oklahoma
    Posts
    3,392
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Thanks. I'm going to keep putting ; at the end though because of personal reasons ... I don't know, perhaps I'm bordering on OCD or something, but it just looks cleaner that way -- and as creole stated -- it will get me into the habbit. Additionally it doesn't affect the way it renders in any browser though ... which I suppose is the most important thing.
    Colin Anderson
    Ambition is a poor excuse for those without
    sense enough to be lazy.


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
  •