• Resolved TheWizardGuy

    (@thewizardguy)


    Let’s say I have a single line of text that I want to emphasize by changing its colour to a dark teal.

    With another theme I was able to create the CSS:

    .entry-content  .text-dark-teal {
    	color: #086e6e;	/* wizard super dark teal */
    }
    

    and then be able to have something like
    <p class="text-dark-teal">Important words here</p>

    I’d love to be able to do this with both pages and posts.

    But I can’t seem to figure out the right class to add the .text-dark-teal to in OceanWP.

    Anyone have any suggestions?

    Thanks

    Lawrence

Viewing 5 replies - 1 through 5 (of 5 total)
  • Can’t you just highlight the text in the text widget and then click the color icon to change it. No code necessary. If you don’t have that option, TinyMCE Advanced plugin provides a number of customization options.

    Hi @thewizardguy,

    I tested your code and it definitely worked.

    Please make sure you have added the CSS code to Appearance – Customize – Custom CSS/JS – CSS Code.

    Thread Starter TheWizardGuy

    (@thewizardguy)

    Les:

    Possibly, but I prefer to use CSS if I can; I have often found that the method you suggest rises up to bite me in the butt every once is a while. The CSS also makes sure that I end up with the “right” colour and if I decide to change the shade of teal, I just have to change the CSS file

    Rajeeb: Hmm. I put it in the CSS file for the child theme this morning and it didn’t work. Will try it again later (sometimes I’ve found that caching does play games and then it goes away); thanks for testing it out for me!

    Lawrence

    Thread Starter TheWizardGuy

    (@thewizardguy)

    Solved it!

    .entry-content  .text-dark-teal {
    whatever
    }

    will change the text colour on a (blog) POST but not a PAGE (like ABOUT) (I guess .entry-content isn’t on pages???)

    but

    .text-dark-teal {
    whatever
    }

    will change it on BOTH. (Haven’t tested it on footers or sidebars yet so my experience there may be different).

    Thanks to everyone who helped!

    Lawrence

    Thread Starter TheWizardGuy

    (@thewizardguy)

    As I mentioned above, it’s resolved.

    Thanks everyone!

    Lawrence

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Changing text colour for a or etc.’ is closed to new replies.