Fed up with your blog’s default text highlight color? Now you can change it with cute colors of your choice by adding this cool CSS3 declaration — ::selection — to the stylesheet of your blog. Here’s how to do it:
| Code: | |
| 1 2 3 4 5 6 |
|
If you want to change the color of the selected (highlighted) text, just add color:, as in the following example:
| Code: | |
| 1 2 3 4 5 6 7 8 |
|
It´s a little something that most visitors will probably never see, but it is a fantastic visual touch for those who do. This nice trick works on all major browsers except IE. As always, IE is left behind. (Which is not a real problem because IE simply ignores the change and shows the default highlight color.)
If you need help in adding the code to your Blogger blog, please leave a comment below.
Good luck!
Special thanks to css-tricks.











1 Comentário:
Post a Comment