:first-letter not working
-
I’m attempting to branch out to new-for-me css territory, psuedo classes! But without any luck.
What I want is for each first letter of headlines to be a different font than the rest of the headline. Most especially entry and post titles and for the main navigation. I already acopmplished this with a span atribute in wordpress, but it’s weird and clunky and doesn’t work at all when the page is automatically translated.
So I took off the span css for the first post, Events, and tried out some :first-letter css in the child theme. None of it is working. I even copied the example of :first-letter styling straight from a tutorial on it, on the p tag. Nothing is working. https://dievilla.at/ is the website.
Anyone know what I’m doing wrong? Or why it’s not working? Here is a list of things I’ve tried, to no avail.
p:first-letter { font-weight: bold; font-size: 300% background-color: red; } h1::first-letter { font-family: 'crimsonbold'; background-color: #999999; } h1.entry-title::first-letter { font-family: 'crimsonbold'; background-color: #999999; } entry-header::first-letter { font-family: 'crimsonbold'; background-color: #999999; } h2::first-letter { font-family: 'crimsonbold'; background-color: #999999; } h2.entry-title::first-letter { font-family: 'crimsonbold'; background-color: #999999; }
- The topic ‘:first-letter not working’ is closed to new replies.