Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

WordPress

Stephen Oxlade
Stephen Oxlade
387 Points

Changing Color of Bullets

Hi,

Using Wordpress and I am trying to change the color of bullets. I have tried using the span command but Wordpress Editor does allow me to save this comment.

Using CSS I can use this to change the color of the bullets: ul > li { color: green; }

But the text changes to this color as well.

Any advice as to how to change the text back to black would be gratefully received !

Many thanks for the help

Stephen

Stephen Oxlade
Stephen Oxlade
387 Points

sorry ... it should read WP editor does NOT allow me to save etc

3 Answers

So, this does not solve your problem? have a look:

ul
{
    list-style-type: square;
}

ul > li
{
    color: green;
}

ul > li > span
{
    color: black;
}

If it does not work for you you can still use a custom list image

ul {
   list-style-image: url('sqpurple.gif');
}
Stephen Oxlade
Stephen Oxlade
387 Points

Hi Martin,

You are a star !! Wordpress stripped out the span tags but used Tiny MCE to get them back in. Your CSS solution works a treat !

Many thanks for coming so quickly with the answer - much appreciated.

Best wishes,

Stephen

Glad it worked for you. Good luck! Martin