Support » Themes and Templates » selected capitalize first letter

  • Resolved noelism

    (@noelism)


    Hello I have a problem with using css .

    p:nth-of-type(1):first-child:first-letter {
    float: left;
    color: black;
    font-family: Impact;
    font-size: 66px;
    font-weight: 700;
    line-height: 40px;
    padding-left: 3px;
    padding-right: 8px;
    padding-top: 5px;
    }

    It capitalize the first letter in blockquote and sidebar widget while I just want to caps it in the first paragraph of the content.

    http://snag.gy/CQauN.jpg

    How do I change this? Thank you in advance.

Viewing 4 replies - 1 through 4 (of 4 total)
  • Try this as the selector:

    .entry-content > p:first-child:first-letter

    Where entry-content is the container for your main content (you didn’t include a link to your site, so I can’t tell what the class name would be).

    Wow thank you so much, man. I’ve tried .entry-content but it’s not working because I dont know I need “>” too. Why do I have to include that by the way?

    Again, thank you so much.

    > means to only select direct children, so only the first-child p which is directly under entry-content would get selected. If you didn’t have it, then any first-child p of any element under entry-content would get selected. In the case of the blockquote, it would be the first-child p element of the blockquote.

    I see, again I cant thank you enough for the enlightenment. May your life always be blessed sir. 🙂

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘selected capitalize first letter’ is closed to new replies.