How to change the colour of selected text using CSS

This very simple piece of CSS will change the colour of selected text, the default is usually blue. You can see this in action on this website, try clicking and dragging the cursor over come text and you will notice that it is orange! As you may have guessed, this working on most browsers but definitely not IE!!

Change selected text color CSS:

::-moz-selection{background:#F69E06;color:#fff;}
::selection {background:#F69E06;color:#fff;}
Free Graphics, Icons, Tutorials
Free Graphics Free File Icon PackFree Fast Food Vector GraphicsFree Music Controls Vector Icon PackFree Spring Birds Graphics PSDFree Business Card Illustrator (AI & EPS) TemplateFree Envelope / Mail Icons PSD
Sharing is caring...
Like & Follow
Share the love, share this page! Facebook Twitter Google Digg Reddit LinkedIn Pinterest Email
Close [X]
The Web Taylor
1000 Lakeside North Harbour Portsmouth, Hampshire PO6 3EN
02392 123358