SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Guru quenting's Avatar
    Join Date
    Dec 2002
    Location
    Switzerland
    Posts
    735
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    :first-letter for any word of a paragraph ?

    the first letter attribute applies to the first letter of any paragraph, is there a way i can set a style for the first letter of any word ina paragraph ?

    Thanks,
    Quentin

  2. #2
    ☆★☆★ silver trophy vgarcia's Avatar
    Join Date
    Jan 2002
    Location
    in transition
    Posts
    21,235
    Mentioned
    1 Post(s)
    Tagged
    1 Thread(s)
    You have to put something else like a <span> in your paragraph:
    Code:
    <head>
    <style type="text/css">
    p {
       font-size: .9em;
    }
     span:first-letter {
       font-size: 1.5em;
    }
    </style>
    </head>
    <body>
    <p>This is a <span>special</span> paragraph.</p>
    Hope this helps!


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
  •