CSS for Excerpt
-
The default color for any text for the page expert function is grey. I want it to be black.
What is the class or ID that WP.com uses for the excerpt element so that I can add the appropriate font color to my CSS?
To get an idea of what I mean, see the front page of the ISEE website. The text in the showcase section is coming from the excerpt field and it is grey (not black).
My theme is Twenty-Eleven. Thanks!
The blog I need help with is: (visible only to logged in users)
-
-
-
Hi there,
You can try the following block of code, entered into the CSS tab of your site customizer here: https://wordpress.com/customize
Here is the code to paste in:
#content .entry-summary { color: #000; }Hope that helps. Please let me know if you have any further questions.
-
Worked like a charm, thanks! I scoured the css for the front page and wasn’t able to isolate the id and class combo that you have. I also would not have know that I need both a class (.entry-summary) and an id (#content). Still learning to use my browsers’ inspect element feature.
Really appreciate the help.
-
Yeah that one was tricky. Usually I don’t add an ID in my CSS rules; classes are just more flexible in my experience. However in this case it was needed to make the declaration specific enough to avoid using !important in my declaration.
This post is probably the best breakdown of the difference between classes and IDs in CSS, if you feel like geeking out: https://css-tricks.com/the-difference-between-id-and-class/
Cheers!
- The topic ‘CSS for Excerpt’ is closed to new replies.