Back to the index.
It's possible to define color
and background
for
text the user selects. And yes, the double colon ::
is required.
Try it below. If you select something and it looks like this, your browser supports selection styles.
This is the paragraph with normal ::selection
.
This is the paragraph with ::-moz-selection
.
p.normal::selection { background:#cc0000; color:#fff; } p.moz::-moz-selection { background:#cc0000; color:#fff; }