Answers for "selection css"

CSS
9

custom selection color css

::selection {
	color: #000000;
	background-color: red;
}

/* for firefox */
::moz-selection {
	color: #000000;
	background-color: red;
}
Posted by: Guest on March-28-2020
2

css selection

::selection {
  background-color: cyan;
}
Posted by: Guest on October-03-2020
1

change mouse highlight color js

/*** Works on common browsers ***/
::selection {
    background-color: #352e7e;
    color: #fff;
}

/*** Mozilla based browsers ***/
::-moz-selection {
    background-color: #352e7e;
    color: #fff;
}

/***For Other Browsers ***/
::-o-selection {
    background-color: #352e7e;
    color: #fff;
}

::-ms-selection {
    background-color: #352e7e;
    color: #fff;
}

/*** For Webkit ***/
::-webkit-selection {
    background-color: #352e7e;
    color: #fff;
}
Posted by: Guest on October-07-2020
0

Css selection

p.normal::selection {
	background: #cc0000;
	color: #fff;
}

p.moz::-moz-selection {
	background: #cc0000;
	color: #fff;
}
Posted by: Guest on August-12-2021
0

selection css

/* Make selected text gold on a red background */
::selection {
  color: gold;
  background-color: red;
}

/* Make selected text in a paragraph white on a blue background */
p::selection {
  color: white;
  background-color: blue;
}
Posted by: Guest on October-10-2021
0

how to add a selection in css

<select>
    <option value="tesla">Tesla</option>
    <option value="volvo">Volvo</option>
    <option value="mercedes">Mercedes</option>
</select">
Posted by: Guest on December-10-2020

Browse Popular Code Answers by Language