Change the Colour of Selected Text Using CSS

Have you ever selected the text on a website and it has been a funky colour and you’ve thought, how do they do that? Well it is very easy using just a few lines of CSS.

You can see this in action on our website, try clicking and dragging the cursor over some text and you will notice that it is orange! This works on most modern browsers but unfortunately not Internet Explorer, why are we not surprised?

::-moz-selection{background:#F60;color:#fff;}
::selection {background:#F60;color:#fff;}
Free Graphics, Icons, Tutorials
Free Graphics Free Christmas Vector Icon Graphics Pack 2017Free Fitness Vector Icons Graphics PackFree Camping Vector Graphics PackFree Summer Graphics PackFree File Icon PackFree Fast Food Vector Graphics
Sharing is caring...
Like & Follow
Share the love, share this page! Facebook Twitter Digg Reddit LinkedIn Pinterest Email
Close [X]
The Web Taylor
1000 Lakeside North Harbour Portsmouth, Hampshire PO6 3EN
02392 123358