Archived topic
Using drop caps and attribute in the same wordpress block
3 replies · Started by Simon on January 13, 2021
Hi,
I'm a html and css newb and trying to get drop caps and the <mark> attribute working inside the same wordpress block.
I am trying to get "Here’s what you will get from Simon Portillo Electrician Services:" inside a <mark> attribute.
Here is the page it's on:
simonportillo.co.uk
Thanks for reading!
Hi there,
try this for your CSS:
P.drop-cap::first-letter {
font-size: 4.5em;
line-height: 1;
float: left;
padding-right: 0.125em;
}
The important part is the line-height property.
For the <mark> you would need to switch the editor to code view, and the HTML for that text block would be something like this:
<p class="drop-cap">Beginning of paragraph with the drop cap, followed by the <mark>text within the mark element</mark></p>
Hi David,
Thank you so much !!! That is working exactly as intended!
Best wishes
Simon
Glad to hear that!