In this article we will find How to Change the Color of Selected Text.This is very simple and basic tips for the web designers and developers. Whenever a person select a text , its color changes to defined color. For example, on my blog theme ,if you select some text you will notice sky blue color in place of default color. Simply add these few lines in your css documents.
[ad#co-1]
[code lang="css"] ::-moz-selection{ background:#C1EEFB ;color:#000 } ::selection{ background:#C1EEFB; color:#000 } [/code]
This property is not supported by IE. View Demo
let us know your thoughts? If you found any other tutorials that you want to share with us,feel free to let us know by dropping in a comment.
Pingback: tripwire magazine | tripwire magazine
Pingback: 95+ Fresh Community Posts for Web Designers and Developers | tripwire magazine
Pingback: 95+ Fresh Community Posts for Web Designers and Developers | Afif Fattouh - Web Specialist
what we have to do for IE
.-= kathirvel mariappan´s last blog ..google =-.
This article has been shared on favSHARE.net. Go and vote it!
.-= favSHARE´s last blog ..Make Money Online With Domain Purchase =-.
Pingback: Linkhub – Woche 04-2010 « pehbehbeh
Thanks for the code i have used it on my blog.
I’ve always wanted to know how to change the highlight colour, thanks a lot
http://www.handycss.com/how/how-to-change-the-text-selection-color-with-css/