Search
 
SCRIPT & CODE EXAMPLE
 

CSS

css if select has value

//if select has this value
select > option[value="someValue"] {background: #ccc;}

//if select has this value selected
select > option[value="someValue"]:checked {background: #ccc;}
Comment

PREVIOUS NEXT
Code Example
Css :: tailwind css absolute pin 
Css :: angular css path to assets 
Css :: in flex-wrap remove last item margin for every row 
Css :: .row bootstrap 
Css :: custom select dropdown css only codepen 
Css :: make clicks pass through element css html 
Css :: css flexbox 
Css :: css change multiple classes 
Css :: flexbox space between 
Css :: for...of...loop and NodeLists 
Css :: css padding attribute order 
Css :: z-index 
Css :: nav bar without display:flex 
Css :: css when i add a border radius to input problem 
Css :: fontawesome trash icon 
Css :: how to remove the body margin from navbar in css 
Css :: css multiple selectors 
Css :: css line-through with words 
Css :: css basic template 
Css :: svg as background css 
Css :: scrollbar 
Css :: back button css 
Css :: youtube no related videos embed 
Css :: css wavy line 
Css :: how to fix rough text html 
Css :: buttons have strange style iOS 
Css :: css in head or body 
Css :: background with three line color css 
Css :: html css text between Horizontal line 
Css :: images end then start text in css 
ADD CONTENT
Topic
Content
Source link
Name
4+5 =