0

I want to know how I can style the backgourund of text like this as shown in imgae I snipt it from here

enter image description here

1

Add span tag to text you want background for and apply css- background-color and font-style: italic on span

    <p><span class="red">VDD</span> GND is used for driving the internal logic circuitry</p>

Then add the following into your WordPress CSS (your theme will have a css file, but may have a place to add custom styles in the Dashboard).

.red {
    background-color: red;
    padding: 0px 5px;
    color: #fff;
    border-radius: 3px;
    display: inline-block;
    -webkit-transform: skew(-10deg);
    -ms-transform: skew(-10deg);
    transform: skew(-10deg);
    -moz-transform: skew(-10deg);
    -o-transform: skew(-10deg);
}
  • Thanks you very much for your help thank you – sandeep sharma Sep 26 at 9:21

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.